MCPcopy Create free account
hub / github.com/GoSimplicity/LinkMe / ListMenus

Method ListMenus

internal/repository/menu.go:57–63  ·  view source on GitHub ↗

ListMenus 分页获取菜单列表

(ctx context.Context, page, pageSize int)

Source from the content-addressed store, hash-verified

55
56// ListMenus 分页获取菜单列表
57func (m *menuRepository) ListMenus(ctx context.Context, page, pageSize int) ([]*domain.Menu, int, error) {
58 menus, total, err := m.dao.ListMenus(ctx, page, pageSize)
59 if err != nil {
60 return nil, 0, err
61 }
62 return m.menusFromDAO(menus), total, nil
63}
64
65// GetMenuTree 获取菜单树
66func (m *menuRepository) GetMenuTree(ctx context.Context) ([]*domain.Menu, error) {

Callers

nothing calls this directly

Calls 2

menusFromDAOMethod · 0.95
ListMenusMethod · 0.65

Tested by

no test coverage detected