| | |
| | | '/auth-redirect', |
| | | '/bind', |
| | | '/register', |
| | | '/oauthLogin/gitee' |
| | | '/oauthLogin/gitee', |
| | | '/calling-screen-big', |
| | | '/calling-screen-room' |
| | | ] |
| | | |
| | | // 路由加载前 |
| | |
| | | console.info("router.beforeEach to: " + to.fullPath + " from: " + from.fullPath) |
| | | start() |
| | | loadStart() |
| | | |
| | | if (whiteList.indexOf(to.path) !== -1) { |
| | | next() |
| | | return |
| | | } |
| | | |
| | | if (!getAccessToken()) { |
| | | if (whiteList.indexOf(to.path) !== -1) { |
| | | next() |
| | | return |
| | | } else { |
| | | next(`/login?redirect=${to.fullPath}`) // 否则全部重定向到登录页 |
| | | return |
| | | } |
| | | next(`/login?redirect=${to.fullPath}`) // 否则全部重定向到登录页 |
| | | return |
| | | } |
| | | |
| | | if (to.path === '/login') { |