fix: modify

develop
时启龙 2024-08-30 09:33:44 +08:00
parent 18f8bdf605
commit f5915f418b
2 changed files with 8 additions and 4 deletions

View File

@ -152,7 +152,6 @@ const actions = {
if (redirectToLogin) { if (redirectToLogin) {
dispatch('ukey/Logout', null, { root: true }).then(res => { dispatch('ukey/Logout', null, { root: true }).then(res => {
console.log('调用天融信单点退出系统 dispatch(ukey/Logout) 方法 res:', res) console.log('调用天融信单点退出系统 dispatch(ukey/Logout) 方法 res:', res)
if (!res.success) return
reset() reset()
}) })
} else { } else {

View File

@ -87,12 +87,17 @@ const actions = {
Logout() { Logout() {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
// 调用天融信单点退出系统 // 调用天融信单点退出系统
const trxToken = getTrxToken()
if (!trxToken) reject(new Error('未找到 trxToken'))
console.log('开始调用天融信 offlineToken') console.log('开始调用天融信 offlineToken')
const trxToken = getTrxToken()
if (!trxToken) {
console.log('调用天融信登出接口,没有获取到 trxToken')
resolve({
success: false
})
return
}
offlineToken(trxToken).then( offlineToken(trxToken).then(
res => { res => {
console.log('调用天融信单点退出系统', res)
resolve(res) resolve(res)
}, },
err => { err => {