increate model limits
This commit is contained in:
parent
b519170c06
commit
5df751f5ca
@ -13,8 +13,8 @@ import (
|
||||
// Otherwise, the sensitive information will be saved on local storage in plain text!
|
||||
type User struct {
|
||||
Id int `json:"id"`
|
||||
Username string `json:"username" gorm:"unique;index" validate:"max=12"`
|
||||
Password string `json:"password" gorm:"not null;" validate:"min=8,max=20"`
|
||||
Username string `json:"username" gorm:"unique;index" validate:"max=30"`
|
||||
Password string `json:"password" gorm:"not null;" validate:"min=8,max=30"`
|
||||
DisplayName string `json:"display_name" gorm:"index" validate:"max=20"`
|
||||
Role int `json:"role" gorm:"type:int;default:1"` // admin, common
|
||||
Status int `json:"status" gorm:"type:int;default:1"` // enabled, disabled
|
||||
|
Loading…
Reference in New Issue
Block a user