Documentation ¶ Index ¶ func ListVirtualMachine(tree string, p *models.PaginationQ) (host []cmdb.VirtualMachine, err error) type DataRes type TreeList func GetMenu(pid int, echo int) []*TreeList Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func ListVirtualMachine ¶ func ListVirtualMachine(tree string, p *models.PaginationQ) (host []cmdb.VirtualMachine, err error) Types ¶ type DataRes ¶ type DataRes struct { Data []*TreeList `json:"treeData"` } type TreeList ¶ type TreeList struct { ID int `json:"id"` Name string `json:"name"` ParentId int64 `json:"parent_id"` Hide int `json:"hide"` SortId int `json:"sort_id"` Children []*TreeList `json:"children"` } func GetMenu ¶ func GetMenu(pid int, echo int) []*TreeList GetMenu 生成目录树 Source Files ¶ View all Source files host.go tree.go Click to show internal directories. Click to hide internal directories.