Quellcode durchsuchen

Merge branch 'develop' of gitadmin/tuoheng_pilot_web into release

pull/123/head
zhangtao vor 1 Jahr
Ursprung
Commit
f275bfafdc
1 geänderte Dateien mit 13 neuen und 10 gelöschten Zeilen
  1. +13
    -10
      src/views/login/index.vue

+ 13
- 10
src/views/login/index.vue Datei anzeigen

import { useUserStore } from '@/store/modules/user' import { useUserStore } from '@/store/modules/user'
import { signinRedirectCallback, signoutRedirectCallback, signoutRedirect, getPath, removePath } from '@/utils/oidc/index.js' import { signinRedirectCallback, signoutRedirectCallback, signoutRedirect, getPath, removePath } from '@/utils/oidc/index.js'
import { updateLoginTime } from '@/api/dashboard/index' import { updateLoginTime } from '@/api/dashboard/index'
import { nextTick } from '@vue/runtime-core'


export default { export default {
name: 'LoginPage', name: 'LoginPage',
// router.push({ path: getPath() }) // router.push({ path: getPath() })
// removePath() // removePath()
userStore.getUserInfos() userStore.getUserInfos()
const authority = res.profile.authority
const { VITE_PLATFORM } = import.meta.env
if (authority && (authority.includes(VITE_PLATFORM))) {
router.push({ path: '/' })
} else {
$message.error('暂无权限访问,请联系管理员')
setTimeout(() => {
signoutRedirect()
}, 2000)
}
nextTick(() => {
const authority = res.profile.authority
const { VITE_PLATFORM } = import.meta.env
if (authority && (authority.includes(VITE_PLATFORM))) {
router.push({ path: '/' })
} else {
$message.error('暂无权限访问,请联系管理员')
setTimeout(() => {
signoutRedirect()
}, 2000)
}
})
}).catch(err => { }).catch(err => {
console.log(err) console.log(err)
signoutRedirect() signoutRedirect()

Laden…
Abbrechen
Speichern