Skip to content

Commit 9679a6d

Browse files
moon6967gitee-org
authored andcommitted
fix: 修复单个顶级菜单加载报错的问题
修复 https://gitee.com/yudaocode/yudao-ui-admin-vue3/issues/IBRPG0 并兼容 https://gitee.com/yudaocode/yudao-ui-admin-vue3/issues/IB9N2J Signed-off-by: chenting <1016830869@qq.com>
1 parent b63179e commit 9679a6d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/utils/routerHelper.ts

+3
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,9 @@ export const generateRoute = (routes: AppCustomRouteRecordRaw[]): AppRouteRecord
100100
//处理顶级非目录路由
101101
if (!route.children && route.parentId == 0 && route.component) {
102102
data.component = Layout
103+
data.meta = {
104+
hidden: meta.hidden,
105+
}
103106
data.name = toCamelCase(route.path, true) + 'Parent'
104107
data.redirect = ''
105108
meta.alwaysShow = true

0 commit comments

Comments
 (0)