Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Button ¶
type Button struct {
domain.AuditingEnabled
ButtonInfo
}
type ButtonArray ¶
type ButtonArray []struct {
MenuId int64 `json:"menu_id"`
ButtonId int64 `json:"button_id"`
RequestUrl string `json:"request_url"`
RequestMethod string `json:"request_method"`
Remark string `json:"remark,omitempty"`
Status int64 `json:"status"`
CreatedTime string
LastModifiedTime string
}
数据类型被使用时,shouldbindjson 对于数字是可以接受 int int64 float64, shouldbind 函数对于数字只能接受 float64
type ButtonInfo ¶ added in v0.0.15
type ButtonInfo struct {
OperationInfo
Color string `gorm:"column:color" json:"color,omitempty"`
AllowMethod string `gorm:"column:allow_method" json:"allowMethod,omitempty"`
}
type Menu ¶
type Menu struct {
domain.AuditingEnabled
MenuInfo
Children []*Menu `gorm:"-" json:"children,omitempty"`
Buttons []*Button `gorm:"foreignkey:Fid" json:"buttons,omitempty"`
}
type MenuButton ¶
type MenuButton struct {
MenuButtonRelation
Id int64 `gorm:"->" json:"id" primaryKey:"yes"`
Fid int64 `gorm:"->" json:"fid" fid:"Id"`
Icon string `gorm:"->" json:"icon,omitempty"`
Name string `gorm:"->" json:"name,omitempty"`
Loading bool `gorm:"->" json:"loading"`
Path string `gorm:"->" json:"path,omitempty"`
Component string `gorm:"->" json:"component,omitempty"`
NodeLevel int `gorm:"->" json:"nodeLevel"`
OutPage bool `gorm:"->" json:"outPage"`
Sort int `gorm:"->" json:"sort"`
Title string `gorm:"->" json:"title,omitempty"`
MenuFid int64 `gorm:"->" json:"menuFid,omitempty"`
ButtonName string `gorm:"->" json:"buttonName,omitempty"`
ButtonColor string `gorm:"->" json:"buttonColor,omitempty"`
NodeType string `gorm:"->" json:"nodeType,omitempty"`
Expand int8 `gorm:"->" json:"expand"`
Children []MenuButton `gorm:"-" json:"children,omitempty"`
}
type MenuButtonRelation ¶
type MenuCreate ¶
type MenuCreate struct {
MenuInfo
ButtonArray `json:"button_array"`
ButtonDelete string `json:"button_delete"`
}
系统菜单以及子表数据结构
type MenuEdit ¶
type MenuEdit struct {
MenuInfo
ButtonArray `json:"button_array"`
ButtonDelete string `json:"button_delete"`
Id int64 `json:"id"`
}
菜单主表以及子表修改的数据结构
type MenuInfo ¶ added in v0.0.15
type MenuInfo struct {
OperationInfo
domain.ParametersEnabled
Path string `gorm:"column:path" json:"path,omitempty"`
Component string `gorm:"column:component" json:"component,omitempty"`
OutPage bool `gorm:"column:out_page" json:"outPage"`
Hidden bool `gorm:"column:hidden;default:0" json:"hidden"`
}
type Module ¶ added in v0.0.21
type Module struct {
domain.AuditingModel
ModuleInfo
Leaf bool `gorm:"-" json:"leaf"`
Children []*Module `gorm:"-" json:"children,omitempty"`
}
type ModuleInfo ¶ added in v0.0.21
type ModuleInfo struct {
Name string `gorm:"column:name" json:"name"`
Title string `gorm:"column:title" json:"title,omitempty"`
Description string `gorm:"column:description" json:"description,omitempty"`
Type string `gorm:"column:type;default:MODULE" json:"type"`
Oid int64 `gorm:"column:oid;default:null" json:"oid,omitempty"`
Fid int64 `gorm:"column:fid;default:null" json:"fid,omitempty"`
Fids string `gorm:"column:fids" json:"fids"`
Path string `gorm:"column:path" json:"path"`
Status int `gorm:"column:status;default:1" json:"status"`
}
type Operation ¶ added in v0.0.15
type Operation struct {
OperationInfo
Children []*Operation `gorm:"-" json:"children,omitempty"`
}
type OperationInfo ¶ added in v0.0.15
type OperationInfo struct {
domain.PropertiesEnabled
Id int64 `gorm:"primaryKey" json:"id" primaryKey:"yes"`
Fid int64 `gorm:"column:fid;default:0" json:"fid" fid:"Id"`
Name string `gorm:"column:name" json:"name"`
Icon string `gorm:"column:icon" json:"icon,omitempty"`
Title string `gorm:"column:title" json:"title,omitempty"`
Type string `gorm:"column:type;->" json:"type"`
Tags string `gorm:"column:tags" json:"tags,omitempty"`
Sort int `gorm:"column:sort;default:100" json:"sort"`
Status int `gorm:"column:status;default:1" json:"status"`
Remark string `gorm:"column:remark" json:"remark,omitempty"`
Level int `gorm:"column:level;default:0" json:"level"`
}
菜单分配文件相关的数据类型 Type: [menu | button]
type OrganizationAuthority ¶ added in v0.0.15
type OrganizationAuthority struct {
domain.AuditingEnabled
Authority
OrganizationId string `gorm:"column:organization_id;primaryKey" json:"organizationId"`
}
func (*OrganizationAuthority) TableName ¶ added in v0.0.15
func (*OrganizationAuthority) TableName() string
type RoleAuthority ¶ added in v0.0.15
type RoleAuthority struct {
domain.AuditingEnabled
Authority
RoleId string `gorm:"column:role_id;primaryKey" json:"roleId"`
}
func (*RoleAuthority) TableName ¶ added in v0.0.15
func (*RoleAuthority) TableName() string
type RoleMenu ¶
type UserAuthority ¶ added in v0.0.15
type UserAuthority struct {
domain.AuditingEnabled
Authority
UserId string `gorm:"column:user_id;primaryKey" json:"userId"`
}
func (*UserAuthority) TableName ¶ added in v0.0.15
func (*UserAuthority) TableName() string
Click to show internal directories.
Click to hide internal directories.