update
This commit is contained in:
@@ -42,6 +42,7 @@ export const useSystemStore = defineStore("SystemStore", () => {
|
||||
redirect: `/home/${routes[0].path}`,
|
||||
children: []
|
||||
});
|
||||
isRoot.value = false;
|
||||
await router.replace(router.currentRoute.value.fullPath);
|
||||
}
|
||||
|
||||
|
||||
@@ -36,6 +36,8 @@ export const useUserStore = defineStore("UserStore", () => {
|
||||
|
||||
const logout = async () => {
|
||||
isLogin.value = false;
|
||||
userInfo.value = null;
|
||||
token.value = null;
|
||||
const {clearRouter} = useSystemStore();
|
||||
await clearRouter();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user