修复本地开发不走统一登陆
This commit is contained in:
1 parent
c49e8d0d3f
commit
1685b22e1e
12 files changed
+161
-139
No files matched your search
@@ -409,7 +409,7 @@ async function handleLogout() {
|
||||
localStorage.removeItem("tenant");
|
||||
sessionStorage.removeItem("tenant");
|
||||
menuStore.resetMenus();
|
||||
router.push("/login");
|
||||
// clearToken 内部已跳认证中心登出页,本地登录页已下线
|
||||
}
|
||||
|
||||
// 加载模块列表
|
||||
|
||||
@@ -60,7 +60,6 @@
|
||||
|
||||
<script setup>
|
||||
import { ref, onMounted } from "vue";
|
||||
import { useRouter } from "vue-router";
|
||||
import { ElMessage, ElMessageBox } from "element-plus";
|
||||
import { getUserInfo } from "@/api/user";
|
||||
import { useAuthStore } from "@/stores/auth";
|
||||
@@ -76,7 +75,6 @@ import BindPhoneDialog from "./components/BindPhoneDialog.vue";
|
||||
import BindEmailDialog from "./components/BindEmailDialog.vue";
|
||||
import WechatBindCard from "./components/WechatBindCard.vue";
|
||||
|
||||
const router = useRouter();
|
||||
const authStore = useAuthStore();
|
||||
|
||||
const userInfo = ref(null);
|
||||
@@ -179,8 +177,8 @@ const handleLogout = () => {
|
||||
}
|
||||
}
|
||||
|
||||
// clearToken 内部会吊销令牌并跳认证中心登出页,此处不再跳本地登录页
|
||||
authStore.clearToken();
|
||||
router.push("/login");
|
||||
ElMessage.success("已退出登录");
|
||||
}).catch(() => {});
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user