From 882d8aef75737b85d829a149bfbd64c78681ed6b Mon Sep 17 00:00:00 2001 From: caishi <1149225589@qq.com> Date: Fri, 26 Mar 2021 10:04:01 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E5=86=B2=E7=AA=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/tpm/TPMIndexHOC.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/modules/tpm/TPMIndexHOC.js b/src/modules/tpm/TPMIndexHOC.js index 4ec284ba0..f5d52a8e8 100644 --- a/src/modules/tpm/TPMIndexHOC.js +++ b/src/modules/tpm/TPMIndexHOC.js @@ -180,6 +180,15 @@ export function TPMIndexHOC(WrappedComponent) { }) } } + if(response.data && response.data.login){ + if(!response.data.has_gitea_user || (response.data.has_gitea_user && !response.data.is_sync_pwd)){ + this.setState({ + giteaVisible:true, + email:response.data.email, + is_sync_pwd:response.data.is_sync_pwd + }) + } + } } }).catch((error) => { console.log(error)