user model change, add Permission

This commit is contained in:
Havoc412 2024-10-16 18:35:24 +08:00
parent bdaf9ae932
commit a9e8e818be
2 changed files with 5 additions and 4 deletions

View File

@ -45,7 +45,6 @@ func WebRegisterValidator() {
// Tag Animal
key = consts.ValidatorPrefix + "AnimalList"
containers.Set(key, animal.List{})
key = consts.ValidatorPrefix + "AnimalDetail"
containers.Set(key, animal.Detail{})
}

View File

@ -26,13 +26,15 @@ type UsersModel struct {
Pass string `json:"-"` // INFO 暂时用不到,但先保留。
Phone string `json:"phone"`
RealName string `gorm:"column:real_name" json:"real_name"`
// TAG 微信
OpenId string `gorm:"column:open_id;size:35" json:"open_id"`
SessionKey string `gorm:"column:session_key;size:35" json:"session_key"`
// TAG 状态管理
Status int `json:"status"` // QUESTION
Token string `json:"token"`
LastLoginIp string `gorm:"column:last_login_ip" json:"last_login_ip"`
// TAG MySELF
Permissions int `json:"permissions"`
// TAG 微信登录相关
OpenId string `gorm:"column:open_id;size:35" json:"open_id"`
SessionKey string `gorm:"column:session_key;size:35" json:"session_key"`
}
// 表名