From 22c377cd574a92f3ce7cef8c820a5793a8cbf02f Mon Sep 17 00:00:00 2001 From: lyc Date: Wed, 9 Oct 2024 09:38:58 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=93=E6=9D=9F=E4=B8=8A=E8=AF=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/renderer/src/layout/components/Header.vue | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/renderer/src/layout/components/Header.vue b/src/renderer/src/layout/components/Header.vue index 212df5c..2d813af 100644 --- a/src/renderer/src/layout/components/Header.vue +++ b/src/renderer/src/layout/components/Header.vue @@ -80,9 +80,7 @@ import { updateUserInfo } from '@/api/system/user' import logoIco from '@/assets/images/logo.png' import { listEvaluation } from '@/api/classManage/index' import { sessionStore } from '@/utils/store' -import { useToolState } from '@/store/modules/tool' -const toolState = useToolState(); let homeTitle = ref(import.meta.env.VITE_APP_TITLE) const { ipcRenderer } = window.electron || {} const userStore = useUserStore() @@ -153,7 +151,8 @@ function handleCommand(command) { function logout() { const hasClass = sessionStore.has('activeClass.id') - if (hasClass || toolState.isToolWin) return ElMessage.warning('当前正在上课,请先结束上课') + const hasTool = sessionStore.get('isToolWin') + if (hasClass || hasTool) return ElMessage.warning('当前正在上课,请先结束上课') ElMessageBox.confirm('确认退出系统吗?', '提示', { confirmButtonText: '确定', cancelButtonText: '取消',