Browse Source

Merge branch 'master' of https://github.com/yudaocode/yudao-ui-admin-vue3

YunaiV 4 months ago
parent
commit
3d4c8f24c7
1 changed files with 4 additions and 0 deletions
  1. 4 0
      src/config/axios/service.ts

+ 4 - 0
src/config/axios/service.ts

@@ -201,6 +201,10 @@ const refreshToken = async () => {
 const handleAuthorized = () => {
 const handleAuthorized = () => {
   const { t } = useI18n()
   const { t } = useI18n()
   if (!isRelogin.show) {
   if (!isRelogin.show) {
+    // 如果已经到登录页面则不进行弹窗提示
+    if (window.location.href.includes('login')) {
+      return
+    }
     isRelogin.show = true
     isRelogin.show = true
     ElMessageBox.confirm(t('sys.api.timeoutMessage'), t('common.confirmTitle'), {
     ElMessageBox.confirm(t('sys.api.timeoutMessage'), t('common.confirmTitle'), {
       showCancelButton: false,
       showCancelButton: false,