mirror of
https://gitee.com/XM-GO/PandaX.git
synced 2026-04-23 02:48:34 +08:00
【优化】租户功能,框架优化
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
||||
type SysRole struct {
|
||||
model.BaseModel
|
||||
RoleId int64 `json:"roleId" gorm:"primary_key;AUTO_INCREMENT"`
|
||||
TenantId int64 `json:"tenantId" gorm:"type:int"`
|
||||
RoleName string `json:"roleName" gorm:"type:varchar(128);comment:角色名称"`
|
||||
Status string `json:"status" gorm:"type:varchar(1);comment:状态"`
|
||||
RoleKey string `json:"roleKey" gorm:"type:varchar(128);comment:角色代码"`
|
||||
|
||||
@@ -12,21 +12,23 @@ type SysUserId struct {
|
||||
}
|
||||
|
||||
type SysUserB struct {
|
||||
NickName string `gorm:"type:varchar(128)" json:"nickName"` // 昵称
|
||||
Phone string `gorm:"type:varchar(11)" json:"phone"` // 手机号
|
||||
RoleId int64 `gorm:"type:int" 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 int64 `gorm:"type:int" json:"deptId"` //部门编码
|
||||
PostId int64 `gorm:"type:int" json:"postId"` //职位编码
|
||||
RoleIds string `gorm:"type:varchar(255)" json:"roleIds"` //多角色
|
||||
PostIds string `gorm:"type:varchar(255)" json:"postIds"` // 多岗位
|
||||
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:varchar(1);" json:"status"`
|
||||
TenantId int64 `gorm:"type:int" json:"tenantId"` //租户id
|
||||
NickName string `gorm:"type:varchar(128)" json:"nickName"` // 昵称
|
||||
Phone string `gorm:"type:varchar(11)" json:"phone"` // 手机号
|
||||
RoleId int64 `gorm:"type:int" 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 int64 `gorm:"type:int" json:"deptId"` //部门编码
|
||||
PostId int64 `gorm:"type:int" json:"postId"` //职位编码
|
||||
RoleIds string `gorm:"type:varchar(255)" json:"roleIds"` //多角色
|
||||
PostIds string `gorm:"type:varchar(255)" json:"postIds"` // 多岗位
|
||||
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:varchar(1);" json:"status"`
|
||||
SysTenants SysTenants `gorm:"foreignKey:TenantId;references:Id" json:"tenants"`
|
||||
model.BaseModel
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user