feat: model type change

This commit is contained in:
zhangwenjian
2020-07-10 00:17:01 +08:00
parent 84a78d7b4f
commit 02cc68daea
20 changed files with 286 additions and 257 deletions
+15 -15
View File
@@ -22,12 +22,12 @@ type User struct {
}
type UserName struct {
Username string `gorm:"type:varchar(64)" json:"username"`
Username string `gorm:"size:64" json:"username"`
}
type PassWord struct {
// 密码
Password string `gorm:"type:varchar(128)" json:"password"`
Password string `gorm:"size:128" json:"password"`
}
type LoginM struct {
@@ -40,19 +40,19 @@ type SysUserId struct {
}
type SysUserB struct {
NickName string `gorm:"type:varchar(128)" json:"nickName"` // 昵称
Phone string `gorm:"type:varchar(11)" json:"phone"` // 手机号
RoleId int `gorm:"type:int(11)" json:"roleId"` // 角色编码
Salt string `gorm:"type:varchar(255)" json:"salt"` //盐
Avatar string `gorm:"type:varchar(255)" json:"avatar"` //头像
Sex string `gorm:"type:varchar(255)" json:"sex"` //性别
Email string `gorm:"type:varchar(128)" json:"email"` //邮箱
DeptId int `gorm:"type:int(11)" json:"deptId"` //部门编码
PostId int `gorm:"type:int(11)" json:"postId"` //职位编码
CreateBy string `gorm:"type:varchar(128)" json:"createBy"` //
UpdateBy string `gorm:"type:varchar(128)" json:"updateBy"` //
Remark string `gorm:"type:varchar(255)" json:"remark"` //备注
Status string `gorm:"type:int(1);" json:"status"`
NickName string `gorm:"size:128" json:"nickName"` // 昵称
Phone string `gorm:"size:11" json:"phone"` // 手机号
RoleId int `gorm:"" json:"roleId"` // 角色编码
Salt string `gorm:"size:255" json:"salt"` //盐
Avatar string `gorm:"size:255" json:"avatar"` //头像
Sex string `gorm:"size:255" json:"sex"` //性别
Email string `gorm:"size:128" json:"email"` //邮箱
DeptId int `gorm:"" json:"deptId"` //部门编码
PostId int `gorm:"" json:"postId"` //职位编码
CreateBy string `gorm:"size:128" json:"createBy"` //
UpdateBy string `gorm:"size:128" json:"updateBy"` //
Remark string `gorm:"size:255" json:"remark"` //备注
Status string `gorm:"size:4;" json:"status"`
DataScope string `gorm:"-" json:"dataScope"`
Params string `gorm:"-" json:"params"`