From 48db4d4b22331f32bf6c6a0956a7cd4245ad6fde Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 29 六月 2023 09:30:34 +0800 Subject: [PATCH] Merge branch 'master' into positec --- src/views/login/index.jsx | 26 +++++++++++++++++++++++--- 1 files changed, 23 insertions(+), 3 deletions(-) diff --git a/src/views/login/index.jsx b/src/views/login/index.jsx index 0f9cfa8..d4c15a5 100644 --- a/src/views/login/index.jsx +++ b/src/views/login/index.jsx @@ -160,7 +160,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('搴旂敤灏氭湭鍒涘缓锛岃鍚戜簯绔悓姝ュ簲鐢紒') @@ -214,7 +220,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('搴旂敤灏氭湭鍒涘缓锛岃鍚戜簯绔悓姝ュ簲鐢紒') @@ -253,7 +265,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('搴旂敤灏氭湭鍒涘缓锛岃鍚戜簯绔悓姝ュ簲鐢紒') @@ -549,6 +567,8 @@ _param.secretkey = Utils.encrypt(_param.LText, _param.timestamp) Api.getSystemConfig(_param).then(res => { + if (!res) return + if (res.status) { // positecgroup res.Banner = res.Banner ? res.Banner.replace(/:8080/ig, '').replace(/http:/ig, 'https:') : '' -- Gitblit v1.8.0