|
@@ -28,8 +28,10 @@ export const useUserStore = defineStore('user',
|
|
|
this.accountInfo = res
|
|
|
localStorage.setItem('accountInfo', JSON.stringify(res))
|
|
|
localStorage.setItem('expiresTime', res.expiresTime) // token过期时间
|
|
|
- this.getUserInfos()
|
|
|
- this.getUserBaseInfos()
|
|
|
+ if (!data.loginType) { // 个人登录
|
|
|
+ this.getUserInfos()
|
|
|
+ this.getUserBaseInfos()
|
|
|
+ }
|
|
|
resolve()
|
|
|
}).catch(err => { reject(err) })
|
|
|
})
|
|
@@ -45,8 +47,10 @@ export const useUserStore = defineStore('user',
|
|
|
this.accountInfo = res
|
|
|
localStorage.setItem('accountInfo', JSON.stringify(res))
|
|
|
localStorage.setItem('expiresTime', res.expiresTime) // token过期时间
|
|
|
- this.getUserInfos()
|
|
|
- this.getUserBaseInfos()
|
|
|
+ if (!data.loginType) { // 个人登录
|
|
|
+ this.getUserInfos()
|
|
|
+ this.getUserBaseInfos()
|
|
|
+ }
|
|
|
resolve()
|
|
|
}).catch(err => { reject(err) })
|
|
|
})
|