package systemuser //菜单 type SystemMenu struct { Id int64 `json:"id" gorm:"column:m_id;type:bigint(20) unsigned;not null;comment:ID"` Title string `json:"title" gorm:"column:m_title;type:varchar(255);not null;comment:菜单名称"` State int `json:"state" gorm:"column:m_steat;type:tinyint(1) unsigned;default:1;not null;comment:是否启用(1:启用;2:禁用;3:删除)"` ParentId int64 `json:"parentId" gorm:"column:m_parent;type:bigint(30) unsigned;default:0;not null;comment:'父级(顶级:0)"` ApiUrl string `json:"apiUrl" gorm:"column:m_url;type:varchar(255);not null;comment:地址"` Time int64 `json:"time" gorm:"column:m_time;type:bigint(30) unsigned;default:0;not null;comment:创建时间"` EiteTime int64 `json:"eiteTime" gorm:"column:m_eite_time;type:bigint(30) unsigned;default:0;not null;comment:修改时间"` UserId int64 `json:"userId" gorm:"column:m_user_id;type:bigint(20) unsigned;not null;default:0;comment:写入人"` Sort int `json:"sort" gorm:"column:m_sort;type:tinyint(3) unsigned;default:0;not null;comment:排序"` } func (SystemMenu *SystemMenu) TableName() string { return "system_menu" } //菜单功能 type MenuOperation struct { OperId int64 `json:"operId" gorm:"column:oper_id;type:bigint(20) unsigned;not null;comment:功能ID"` MenuId int64 `json:"menuId" gorm:"column:menu_id;type:bigint(20) unsigned;not null;default:0;comment:菜单id"` OperTitle string `json:"operTitle" gorm:"column:oper_title;type:varchar(255);not null;comment:操作名称"` } func (MenuOperation *MenuOperation) TableName() string { return "menu_operation" } //菜单管理 type SystemMenuOperation struct { SystemMenu MenuOperation }