Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { Model UUID uuid.UUID `json:"uuid" gorm:"index;unique;comment:用户UUID"` Username string `json:"username" gorm:"size:16;index;unique;comment:用户账号"` Password string `json:"-" gorm:"size:64;comment:用户密码"` Nickname string `json:"nickname" gorm:"size:16;comment:用户昵称"` Phone string `json:"phone" gorm:"size:16;comment:用户手机号"` Status int `json:"status" gorm:"default:1;comment:用户状态"` Roles []Role `json:"roles" gorm:"many2many:sys_account_roles"` }
type Menu ¶
type Menu struct { Model UUID uuid.UUID `json:"uuid" gorm:"index;unique;comment:UUID"` Link string `json:"link" gorm:"size:256;comment:链接"` Perm string `json:"perm" gorm:"size:64;comment:权限值"` Name string `json:"name" gorm:"size:16;comment:名称"` Group string `json:"group" gorm:"size:32;comment:分组"` Pos string `json:"pos" gorm:"size:16;comment:位置"` Icon string `json:"icon" gorm:"size:32;comment:图标"` Auth int `json:"auth" gorm:"default:0;comment:认证"` Status int `json:"status" gorm:"default:1;comment:状态"` }
type Perm ¶
type Role ¶
type Role struct { Model UUID uuid.UUID `json:"uuid" gorm:"index;unique;comment:角色UUID"` Name string `json:"name" gorm:"size:16;unique;comment:角色名称"` Desc string `json:"desc" gorm:"size:256;comment:角色描述"` Status int `json:"status" gorm:"default:1;comment:角色状态"` Perms []RolePerm `json:"perms" gorm:"foreignKey:RoleId;references:UUID"` }
Click to show internal directories.
Click to hide internal directories.