zhouwenxuan
2024-02-27 48b9dbfb66cf8bf6c83dac0f9365ba71d3181fba
src/layout/components/Navbar.vue
@@ -61,6 +61,7 @@
import useAppStore from '@/store/modules/app'
import useUserStore from '@/store/modules/user'
import useSettingsStore from '@/store/modules/settings'
import {removeToken} from "@/utils/auth";
const appStore = useAppStore()
const userStore = useUserStore()
@@ -89,9 +90,9 @@
    cancelButtonText: '取消',
    type: 'warning'
  }).then(() => {
    userStore.logOut().then(() => {
      location.href = '/index';
    })
    removeToken()
    location.href = '/homePage';
  }).catch(() => { });
}