From 75e72bf974fdab85a81845f900f7fc17a9cb0126 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=96=AF=E7=8B=82=E7=9A=84=E7=8B=AE=E5=AD=90Li?= <15040126243@163.com> Date: Thu, 13 Jul 2023 16:19:29 +0800 Subject: [PATCH] =?UTF-8?q?update=20=E4=BC=98=E5=8C=96=20=E4=B8=89?= =?UTF-8?q?=E6=96=B9=E6=8E=88=E6=9D=83=E9=A1=B5=E9=9D=A2=20=E5=BB=B6?= =?UTF-8?q?=E8=BF=9F=E8=B7=B3=E8=BD=AC=E9=81=BF=E5=85=8D=E6=97=A0=E6=B3=95?= =?UTF-8?q?=E6=9F=A5=E7=9C=8B=E9=94=99=E8=AF=AF=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/layout/components/SocialCallback/index.vue | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/layout/components/SocialCallback/index.vue b/src/layout/components/SocialCallback/index.vue index ef02c2d..dd381da 100644 --- a/src/layout/components/SocialCallback/index.vue +++ b/src/layout/components/SocialCallback/index.vue @@ -31,12 +31,16 @@ const processResponse = async (res: any) => { setToken(res.data.access_token); } ElMessage.success(res.msg); - location.href = import.meta.env.VITE_APP_CONTEXT_PATH + 'index'; + setTimeout(() => { + location.href = import.meta.env.VITE_APP_CONTEXT_PATH + 'index'; + }, 2000); }; const handleError = (error: any) => { ElMessage.error(error.message); - location.href = import.meta.env.VITE_APP_CONTEXT_PATH + 'index'; + setTimeout(() => { + location.href = import.meta.env.VITE_APP_CONTEXT_PATH + 'index'; + }, 2000); }; const callbackByCode = async (data: LoginData) => {