|
@@ -46,7 +46,7 @@ const whiteList = ['/Login']
|
|
|
router.beforeEach((to, from, next) => {
|
|
|
// if (to.matched.some(record => record.meta.needLogin)) { // 判断该路由是否需要登录权限
|
|
|
if (!whiteList.includes(to.path)) {
|
|
|
- console.log('有登录权限')
|
|
|
+ console.log('有登录权限',to,to.path)
|
|
|
if (!localStorage.getItem('courierUserId')) { // 判断当前用户的登录信息userId是否存在
|
|
|
console.log('无userId')
|
|
|
next('/Login')
|