Refactor(登录):登录按钮去掉判断逻辑,一直显示

This commit is contained in:
lifizer
2024-10-17 10:05:39 +08:00
parent ca11455148
commit b0ac014816
2 changed files with 31 additions and 34 deletions
+2 -2
View File
@@ -924,10 +924,10 @@ export const handleLoginFailure = () => {
store.commit("logout");
store.commit("updateAuthorization", false);
let currentPageUrl = getCurrentPageUrl()
const currentPageUrl = getCurrentPageUrl()
// token 失效
// 判断当前是不是已经在登录页面或者授权页,防止二次跳转
if (store.getters.isAuthorizationPage || getCurrentPageUrl() == '/pages/user/Login/index') {
if (store.getters.isAuthorizationPage || currentPageUrl == '/pages/user/Login/index' || currentPageUrl === '/pages/authorization/index') {
return
}
store.commit("updateAuthorizationPage", true);