You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
436 B
15 lines
436 B
package request
|
|
|
|
import "sorbet/pkg/v"
|
|
|
|
type SystemAuthLoginRequest struct {
|
|
Username string `json:"username" xml:"username" form:"username"`
|
|
Password string `json:"password" xml:"password" form:"password"`
|
|
}
|
|
|
|
func (r *SystemAuthLoginRequest) Validate() error {
|
|
return v.Validate(
|
|
v.Value(r.Username, "username", "用户名").Required().MinLength(2),
|
|
v.Value(r.Password, "password", "登录密码").Required().MinLength(6),
|
|
)
|
|
}
|
|
|