feat: release v1.0.0
This commit is contained in:
@@ -1,19 +1,22 @@
|
||||
package request
|
||||
|
||||
import (
|
||||
"server/internal/model/common"
|
||||
"server/internal/pkg/validator"
|
||||
)
|
||||
|
||||
type CreateSysUserRequest struct {
|
||||
Username string `json:"username" validate:"required"`
|
||||
Username string `json:"username" validate:"required,min=1,max=50"`
|
||||
Account string `json:"account" validate:"required,min=5,max=100"`
|
||||
Password string `json:"password" validate:"required,min=6,max=255"`
|
||||
AvatarID *int32 `json:"avatar_id" validate:"omitempty"`
|
||||
Status *int16 `json:"status" validate:"oneof=0 1"`
|
||||
}
|
||||
|
||||
type UpdateSysUserRequest struct {
|
||||
Username *string `json:"username" validate:"omitempty,min=0,max=50"`
|
||||
Username *string `json:"username" validate:"omitempty,min=1,max=50"`
|
||||
AvatarID validator.NullInt32 `json:"avatar_id" validate:"omitempty"`
|
||||
Status *int16 `json:"status" validate:"omitempty,oneof=0 1"`
|
||||
}
|
||||
|
||||
type UpdateSysUserPassword struct {
|
||||
@@ -28,3 +31,8 @@ type LoginRequest struct {
|
||||
Account string `json:"account" validate:"required,min=5,max=100"`
|
||||
Password string `json:"password" validate:"required,min=6,max=255"`
|
||||
}
|
||||
|
||||
type SearchSysUserParams struct {
|
||||
common.Pagination
|
||||
Username string `json:"username" validate:"omitempty,max=50"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user