From e7f3835c7ffb0de6747c7c496c590f7f42e455fc Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期三, 24 一月 2024 15:05:33 +0800
Subject: [PATCH] 111

---
 company/src/utils/request.js |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/company/src/utils/request.js b/company/src/utils/request.js
index 2dbe4d3..9821bd0 100644
--- a/company/src/utils/request.js
+++ b/company/src/utils/request.js
@@ -42,7 +42,7 @@
 // 鏂板缓鍝嶅簲鎷︽埅鍣�
 axiosInstance.interceptors.response.use((response) => {
   
-  console.log(response.status)
+  // console.log(response.status)
   // debugger
   // 璇锋眰澶辫触
   if (response.status !== 200) {
@@ -55,7 +55,8 @@
   // 鏈櫥褰�
   if (response.data.code === 401) {
     if (response.config.autoLogin !== false) {
-      window.location.href = process.env.VUE_APP_ROUTER_MODE === 'history' ? '/#/login' : '/login'
+      location.reload()
+      // window.location.href = process.env.VUE_APP_ROUTER_MODE === 'history' ? '/login' : '/#/login'
     }
     return Promise.reject(response.data)
   }

--
Gitblit v1.9.3