From 50821207863ae07b0ab36a604fcbad200a055af9 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期五, 23 六月 2023 00:11:38 +0800
Subject: [PATCH] 2023-06-23

---
 src/views/login/index.jsx |   24 +++++++++++++++++++++---
 1 files changed, 21 insertions(+), 3 deletions(-)

diff --git a/src/views/login/index.jsx b/src/views/login/index.jsx
index 55fba9b..2144a36 100644
--- a/src/views/login/index.jsx
+++ b/src/views/login/index.jsx
@@ -149,7 +149,13 @@
         }
       }
 
-      this.props.history.replace('/main')
+      let iframe = sessionStorage.getItem('iframe')
+      if (iframe) {
+        sessionStorage.removeItem('iframe')
+        this.props.history.replace(iframe.replace(/@loginuid@/, res.LoginUID))
+      } else {
+        this.props.history.replace('/main')
+      }
     } else if (res.ErrCode === 'Need_Get_Appkey' && options.sysType === 'SSO') {
       message.warning('搴旂敤灏氭湭鍒涘缓锛岃鍚戜簯绔悓姝ュ簲鐢紒')
 
@@ -203,7 +209,13 @@
       sessionStorage.removeItem('visitorUserID')
       sessionStorage.removeItem('visitorLoginUID')
 
-      this.props.history.replace('/main')
+      let iframe = sessionStorage.getItem('iframe')
+      if (iframe) {
+        sessionStorage.removeItem('iframe')
+        this.props.history.replace(iframe.replace(/@loginuid@/, res.LoginUID))
+      } else {
+        this.props.history.replace('/main')
+      }
     } else if (res.ErrCode === 'Need_Get_Appkey' && options.sysType === 'SSO') {
       message.warning('搴旂敤灏氭湭鍒涘缓锛岃鍚戜簯绔悓姝ュ簲鐢紒')
 
@@ -242,7 +254,13 @@
         sessionStorage.removeItem('visitorUserID')
         sessionStorage.removeItem('visitorLoginUID')
   
-        this.props.history.replace('/main')
+        let iframe = sessionStorage.getItem('iframe')
+        if (iframe) {
+          sessionStorage.removeItem('iframe')
+          this.props.history.replace(iframe.replace(/@loginuid@/, res.LoginUID))
+        } else {
+          this.props.history.replace('/main')
+        }
       } else if (res.ErrCode === 'Need_Get_Appkey' && options.sysType === 'SSO') {
         message.warning('搴旂敤灏氭湭鍒涘缓锛岃鍚戜簯绔悓姝ュ簲鐢紒')
   

--
Gitblit v1.8.0