fix(route): ensure that the first level menu can be hidden

This commit is contained in:
Vben
2021-03-23 01:06:32 +08:00
parent 908116ddc4
commit e2cc5af937
5 changed files with 26 additions and 20 deletions

View File

@@ -45,6 +45,7 @@ async function getAsyncMenus() {
export const getMenus = async (): Promise<Menu[]> => {
const menus = await getAsyncMenus();
const routes = router.getRoutes();
return !isBackMode() ? filter(menus, basicFilter(routes)) : menus;
};