mirror of
https://github.com/acepanel/panel.git
synced 2026-02-04 10:17:17 +08:00
feat: 优化菜单排序
This commit is contained in:
@@ -47,7 +47,10 @@ function getMenuItem(route: RouteType, basePath = ''): MenuItem {
|
||||
}
|
||||
|
||||
const visibleChildren = route.children
|
||||
? route.children.filter((item: RouteType) => item.name && !item.isHidden)
|
||||
? route.children.filter(
|
||||
(item: RouteType) =>
|
||||
item.name && !item.isHidden && !permissionStore.hiddenRoutes.includes(item.name)
|
||||
)
|
||||
: []
|
||||
|
||||
if (!visibleChildren.length) return menuItem
|
||||
|
||||
@@ -9,7 +9,7 @@ export default {
|
||||
meta: {
|
||||
title: 'Toolbox',
|
||||
icon: 'mdi:tools',
|
||||
order: 80
|
||||
order: 90
|
||||
},
|
||||
children: [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user