From 50f96651c261cd8656f9475c455ffdc0ed261236 Mon Sep 17 00:00:00 2001 From: xingyu Date: Tue, 29 Nov 2022 23:26:58 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=9B=B4=E6=8D=A2=E4=B8=BAlet=20const?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yudao-ui-admin/src/store/modules/permission.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/yudao-ui-admin/src/store/modules/permission.js b/yudao-ui-admin/src/store/modules/permission.js index 3316e945f..a9dbd2b41 100644 --- a/yudao-ui-admin/src/store/modules/permission.js +++ b/yudao-ui-admin/src/store/modules/permission.js @@ -62,7 +62,7 @@ function filterAsyncRouter(asyncRouterMap, lastRouter = false, type = false) { route.name = toCamelCase(route.path, true) // 处理三级及以上菜单路由缓存问题,将path名字赋值给name if (route.path.indexOf("/") !== -1) { - var pathArr = route.path.split("/") + const pathArr = route.path.split("/"); route.name = toCamelCase(pathArr[pathArr.length - 1], true) } route.hidden = !route.visible @@ -91,7 +91,7 @@ function filterAsyncRouter(asyncRouterMap, lastRouter = false, type = false) { } function filterChildren(childrenMap, lastRouter = false) { - var children = [] + let children = []; childrenMap.forEach((el, index) => { if (el.children && el.children.length) { if (!el.component && !lastRouter) {