mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-07-18 21:15:06 +08:00
perf: store
This commit is contained in:
@ -6,6 +6,7 @@ import { useRouter } from 'vue-router'
|
||||
import { useDesign } from '@/hooks/web/useDesign'
|
||||
import avatarImg from '@/assets/imgs/avatar.gif'
|
||||
import { useUserStore } from '@/store/modules/user'
|
||||
import { useTagsViewStore } from '@/store/modules/tagsView'
|
||||
|
||||
const { t } = useI18n()
|
||||
|
||||
@ -15,6 +16,8 @@ const { push, replace } = useRouter()
|
||||
|
||||
const userStore = useUserStore()
|
||||
|
||||
const tagsViewStore = useTagsViewStore()
|
||||
|
||||
const { getPrefixCls } = useDesign()
|
||||
|
||||
const prefixCls = getPrefixCls('user-info')
|
||||
@ -33,6 +36,7 @@ const loginOut = () => {
|
||||
})
|
||||
.then(async () => {
|
||||
userStore.loginOut()
|
||||
tagsViewStore.delAllViews
|
||||
replace('/login')
|
||||
})
|
||||
.catch(() => {})
|
||||
|
Reference in New Issue
Block a user