Skip to content

Commit 6b9c95b

Browse files
author
allen
committed
fix: 过滤菜单项
1 parent b35e26a commit 6b9c95b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/components/layout/Aside.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ const menus = getMenus(router, '')
88
99
function getMenus(route: any, path: string) {
1010
return route
11+
.filter((item: any) => item.meta && item.meta.sort)
1112
.sort((a: any, b: any) => a.meta.sort - b.meta.sort)
1213
.map((item: any) => {
1314
if (item.children && item.children.length > 0) {

0 commit comments

Comments
 (0)