From 0799f543beca64dd1c6007e18cb8d8388b2fc391 Mon Sep 17 00:00:00 2001
From: yaozc2021 <yaozc@yhzhg.cn>
Date: Fri, 22 Nov 2024 01:29:02 +0000
Subject: [PATCH] update
---
eladmin-web-master/src/router/index.js | 6 ------
1 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/eladmin-web-master/src/router/index.js b/eladmin-web-master/src/router/index.js
index 247d83f..47be649 100644
--- a/eladmin-web-master/src/router/index.js
+++ b/eladmin-web-master/src/router/index.js
@@ -15,7 +15,6 @@
if (to.meta.title) {
document.title = to.meta.title + ' - ' + Config.title
}
- console.log('to.path : ', to.path)
NProgress.start()
if (getToken()) {
// 已登录且要跳转的页面是登录页
@@ -24,7 +23,6 @@
NProgress.done()
} else {
if (store.getters.roles.length === 0) { // 判断当前用户是否已拉取完user_info信息
- console.log('1111111111111111111111111111111111111111111111111')
store.dispatch('GetInfo').then(() => { // 拉取user_info
// 动态路由,拉取菜单
loadMenus(next, to)
@@ -35,12 +33,10 @@
})
// 登录时未拉取 菜单,在此处拉取
} else if (store.getters.loadMenus) {
- console.log('222222222222222222222222222222222222222222222222222')
// 修改成false,防止死循环
store.dispatch('updateLoadMenus')
loadMenus(next, to)
} else {
- console.log('33333333333333333333333333333333333333333333333333')
next()
}
}
@@ -56,7 +52,6 @@
})
export const loadMenus = (next, to) => {
- console.log('44444444444444444444444444444444444444444444')
buildMenus().then(res => {
const sdata = JSON.parse(JSON.stringify(res))
const rdata = JSON.parse(JSON.stringify(res))
@@ -66,7 +61,6 @@
store.dispatch('GenerateRoutes', rewriteRoutes).then(() => { // 存储路由
router.addRoutes(rewriteRoutes) // 动态添加可访问路由表
- console.log('to.path2 : ', to.path)
next({ ...to, replace: true })
})
store.dispatch('SetSidebarRouters', sidebarRoutes)
--
Gitblit v1.9.3