Versions in this module Expand all Collapse all v0 v0.1.0 Apr 4, 2024 Changes in this version + const EntityNotFound + const ErrCodeAlreadyExists + const ErrCodeForbidden + const ErrCodeInternalError + const ErrCodeInvalidParams + const ErrCodeNotFound + const ErrCodeUnauthorized + const FailedToAddNode + const FailedToDeleteNode + const FailedToGetNode + const FieldError + const FieldInvalid + const FieldNotMatch + const FieldNotUnique + const FieldTooBig + const FieldTooLong + const FieldTooShort + const FieldTooSmall + var Validate = validator.New(validator.WithRequiredStructEnabled()) + func BindParamAndValidate[T interface{}](c *gin.Context, obj *T) + func SerializeDataAndValidate[T interface{}](source T, target *T, doSerialize ...bool) T + func SerializeData[T interface{}](source any, target *T) T + func SuccessHandler(c *gin.Context, responseData interface{}) + func ValidateSchema[T interface{}](source T) T + func ValidateStruct(i interface{}) error + type KnownError struct + Code int + Data interface{} + Msg string + func NewKnownError(code int, data interface{}, msg string) *KnownError + func (e *KnownError) Error() string