修复登录问题
This commit is contained in:
parent
4aca6defd4
commit
af35ad5e80
|
@ -206,7 +206,7 @@ export default {
|
|||
prototype.$storage.set('user_access_token', null);
|
||||
prototype.$storage.set('userinfo', null);
|
||||
$store.commit('user/token', "");
|
||||
prototype.$utils.toast('注销成功').then(() => {
|
||||
prototype.$utils.toast('请重新登录').then(() => {
|
||||
prototype.$utils.toPage('/pages/index/index', {}, 'switch');
|
||||
});
|
||||
}
|
||||
|
|
|
@ -59,7 +59,7 @@ const request = async (args) => {
|
|||
}
|
||||
|
||||
if (response.data.code == 10001) {
|
||||
$store.dispatch("user/logout");
|
||||
prototype.$models.user.logout();
|
||||
$store.commit("user/showLoginModal", true);
|
||||
throw "登录态失效";
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue