|
|
@@ -116,14 +116,15 @@ router.beforeEach(async (to, from, next) => {
|
|
|
}
|
|
|
}
|
|
|
} else {
|
|
|
- if (to.fullPath.includes('sso') && to.fullPath.includes('username')) {
|
|
|
+ if (to.query.username) {
|
|
|
+ await getTenantId()
|
|
|
const res = await LoginApi.portalLogin({
|
|
|
username: to.query.username
|
|
|
})
|
|
|
|
|
|
authUtil.setToken(res)
|
|
|
- await getTenantId()
|
|
|
- next({ path: 'index' })
|
|
|
+
|
|
|
+ next({ path: '/' })
|
|
|
} else if (whiteList.indexOf(to.path) !== -1) {
|
|
|
const code = to.query.code
|
|
|
if (code) {
|