57 lines
1.2 KiB
Go
57 lines
1.2 KiB
Go
package db
|
|
|
|
import "time"
|
|
|
|
type SysDepartmentDto struct {
|
|
ID int32 `json:"id"`
|
|
// 部门名称
|
|
Name string `json:"name"`
|
|
// 上级id
|
|
ParentID int32 `json:"parent_id"`
|
|
// 树路径
|
|
ParentPath string `json:"parent_path"`
|
|
// 状态
|
|
Status int32 `json:"status"`
|
|
// 排序
|
|
Sort int32 `json:"sort"`
|
|
// 创建时间
|
|
CreatedAt time.Time `json:"created_at"`
|
|
// 更新时间
|
|
UpdatedAt time.Time `json:"updated_at"`
|
|
Children []*SysDepartmentDto `json:"children"`
|
|
}
|
|
|
|
type SysMenuDto struct {
|
|
ID int32 `json:"id"`
|
|
// 名称
|
|
Name string `json:"name"`
|
|
// 显示名称
|
|
DisplayName string `json:"display_name"`
|
|
// 菜单url
|
|
Url string `json:"url"`
|
|
// 菜单类型(node, menu, btn)
|
|
Type string `json:"type"`
|
|
// 上级id
|
|
ParentID int32 `json:"parent_id"`
|
|
// 树路径
|
|
ParentPath string `json:"parent_path"`
|
|
// 菜单图标
|
|
Avatar string `json:"avatar"`
|
|
// 菜单样式
|
|
Style string `json:"style"`
|
|
// 是否可见
|
|
Visible bool `json:"visible"`
|
|
// 是否列表
|
|
IsList bool `json:"is_list"`
|
|
// 状态
|
|
Status int32 `json:"status"`
|
|
// 排序
|
|
Sort int32 `json:"sort"`
|
|
// 创建时间
|
|
CreatedAt time.Time `json:"created_at"`
|
|
// 更新时间
|
|
UpdatedAt time.Time `json:"updated_at"`
|
|
|
|
Children []*SysMenuDto `json:"children"`
|
|
}
|