From a3f920c3aa61a1bbbdf042163ea194f092ae466d Mon Sep 17 00:00:00 2001
From: 罗广辉 <guanghui.luo@foxmail.com>
Date: Wed, 11 Mar 2026 12:12:18 +0800
Subject: [PATCH] feat: 退出登录

---
 applications/task-work-order/src/store/modules/user.js |   11 ++---------
 1 files changed, 2 insertions(+), 9 deletions(-)

diff --git a/applications/task-work-order/src/store/modules/user.js b/applications/task-work-order/src/store/modules/user.js
index 6c4c7a1..a5d6cbe 100644
--- a/applications/task-work-order/src/store/modules/user.js
+++ b/applications/task-work-order/src/store/modules/user.js
@@ -1,7 +1,7 @@
 import { setToken, setRefreshToken, removeToken, removeRefreshToken, getRefreshToken } from '@/utils/auth'
 import { setStore, getStore } from '@/utils/store'
 import { validatenull } from '@/utils/validate'
-import { deepClone } from '@/utils/util'
+import { deepClone, logOutFun } from '@/utils/util'
 import defaultAva from '@/assets/images/defaultava.png'
 import {
 	loginByUsername,
@@ -261,14 +261,7 @@
 		},
 		GetMenu({ commit, dispatch }, tenantId) {
 			const errLogOut = () => {
-				dispatch('LogOut').then(() => {
-					const env = import.meta.env.VITE_APP_ENV
-					const adminUrl = import.meta.env.VITE_APP_DASHBOARD_URL
-					(window.location.href = '/task-work-order/login')
-					// env === 'development'
-					// 	? (window.location.href = '/task-work-order/login')
-					// 	: window.location.replace(`${adminUrl}#/login`)
-				})
+				logOutFun()
 			}
 			return new Promise(resolve => {
 				getRoutes({ tenantId, sysType: 6 })

--
Gitblit v1.9.3