Documentation ¶
Index ¶
- Variables
- func Create(c echo.Context) error
- func CurrentUserInfo(c echo.Context) error
- func Delete(c echo.Context) error
- func List(c echo.Context) error
- func Login(ctx echo.Context) error
- func Logout(ctx echo.Context) error
- func Update(c echo.Context) error
- type LoginForm
- type LoginResponseContent
- type Serializer
- func (c *Serializer) ExtraFilter(query map[string]interface{}) map[string]interface{}
- func (c *Serializer) GetParams() base.SerializersParams
- func (c *Serializer) Order() []string
- func (c *Serializer) Preload() []string
- func (c *Serializer) QueryBeforeHook(ctx echo.Context, tx *gorm.DB, query map[string]interface{}) (*gorm.DB, error)
- func (c *Serializer) Response(data base.ResponseContent, query map[string]interface{}) base.ResponseContent
Constants ¶
This section is empty.
Variables ¶
View Source
var ( FieldFilterCondition = []base.SerializersField{ { Field: "id", Type: base.ContainsExpressionEnum, }, { Field: "username", Type: base.LikeExpressionEnum, }, { Field: "name", Type: base.LikeExpressionEnum, }, { Field: "email", Type: base.LikeExpressionEnum, }, { Field: "isAdmin", Column: "is_admin", Type: base.EqualExpressionEnum, }, { Field: "isActive", Column: "is_active", Type: base.EqualExpressionEnum, }, { Field: "groupId", Column: "group_id", Type: base.EqualExpressionEnum, }, { Field: "users", Column: "username", Type: base.ContainsExpressionEnum, }, { Field: "userIds", Column: "id", Type: base.ContainsExpressionEnum, }, } )
Functions ¶
func CurrentUserInfo ¶
func CurrentUserInfo(c echo.Context) error
Types ¶
type LoginResponseContent ¶
type Serializer ¶
type Serializer struct { Filter map[string]interface{} // contains filtered or unexported fields }
func NewSerializer ¶
func NewSerializer() *Serializer
func (*Serializer) ExtraFilter ¶
func (c *Serializer) ExtraFilter(query map[string]interface{}) map[string]interface{}
func (*Serializer) GetParams ¶
func (c *Serializer) GetParams() base.SerializersParams
func (*Serializer) Order ¶
func (c *Serializer) Order() []string
func (*Serializer) Preload ¶
func (c *Serializer) Preload() []string
func (*Serializer) QueryBeforeHook ¶
func (*Serializer) Response ¶
func (c *Serializer) Response(data base.ResponseContent, query map[string]interface{}) base.ResponseContent
Click to show internal directories.
Click to hide internal directories.