Documentation ¶
Index ¶
- type MenuDao
- func (d *MenuDao) BuildMenuTree(menus []*models.Menu, parentID uint) []*models.MenuTree
- func (d *MenuDao) CreateMenu(menu *models.Menu) error
- func (d *MenuDao) DeleteMenu(id uint) error
- func (d *MenuDao) GetMenuByID(id uint) (*models.Menu, error)
- func (d *MenuDao) GetMenus() ([]*models.Menu, error)
- func (d *MenuDao) GetMenusByPermissions(permissions []string) ([]*models.Menu, error)
- func (d *MenuDao) UpdateMenu(menu *models.Menu) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MenuDao ¶
type MenuDao struct { }
func NewMenuDao ¶
func NewMenuDao() *MenuDao
func (*MenuDao) BuildMenuTree ¶
BuildMenuTree 构建菜单树
func (*MenuDao) GetMenuByID ¶
GetMenuByID 根据ID获取菜单
func (*MenuDao) GetMenusByPermissions ¶
GetMenusByPermissions 根据权限获取菜单
Click to show internal directories.
Click to hide internal directories.