From cb29c2c0aa14475d0dab9b35a117ca158edb76f6 Mon Sep 17 00:00:00 2001 From: YunaiV Date: Sat, 7 Sep 2024 14:28:02 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90BUG=E4=BF=AE=E5=A4=8D=E3=80=91?= =?UTF-8?q?=E6=8E=88=E6=9D=83=E7=99=BB=E5=BD=95=E6=88=90=E5=8A=9F=E5=90=8E?= =?UTF-8?q?=EF=BC=8C=E6=AF=8F=E6=AC=A1=E9=83=BD=E8=A6=81=E5=A1=AB=E6=98=B5?= =?UTF-8?q?=E7=A7=B0=E5=92=8C=E9=87=8D=E6=96=B0=E4=B8=8A=E4=BC=A0=E5=A4=B4?= =?UTF-8?q?=E5=83=8F=E3=80=82=C2=A0=C2=A0=C2=A0=C2=A0=20=E5=A6=82=E6=9E=9C?= =?UTF-8?q?=E7=94=A8=E6=88=B7=E5=B7=B2=E7=BB=8F=E6=9C=89=E5=A4=B4=E5=83=8F?= =?UTF-8?q?=E5=92=8C=E6=98=B5=E7=A7=B0=EF=BC=8C=E5=88=99=E4=B8=8D=E8=A6=81?= =?UTF-8?q?=E5=BC=B9=E5=87=BA=E4=B8=8A=E4=BC=A0=E5=A4=B4=E5=83=8F=E5=92=8C?= =?UTF-8?q?=E5=A1=AB=E5=86=99=E6=98=B5=E7=A7=B0=E7=9A=84=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E5=BC=B9=E6=A1=86=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/s-auth-modal/s-auth-modal.vue | 32 +++++++++++-------- 1 file changed, 18 insertions(+), 14 deletions(-) diff --git a/sheep/components/s-auth-modal/s-auth-modal.vue b/sheep/components/s-auth-modal/s-auth-modal.vue index 204f703..41a7dbb 100644 --- a/sheep/components/s-auth-modal/s-auth-modal.vue +++ b/sheep/components/s-auth-modal/s-auth-modal.vue @@ -10,7 +10,11 @@ /> - + @@ -32,7 +36,11 @@ 还没有账号? - @@ -81,17 +89,13 @@ /> 我已阅读并遵守 - - 《用户协议》 - + 《用户协议》 - - 《隐私协议》 - + 《隐私协议》 - + @@ -107,8 +111,6 @@ import mpAuthorization from './components/mp-authorization.vue'; import { closeAuthModal, showAuthModal } from '@/sheep/hooks/useModal'; - const appInfo = computed(() => sheep.$store('app').info); - const modalStore = sheep.$store('modal'); // 授权弹窗类型 const authType = computed(() => modalStore.auth); @@ -154,9 +156,11 @@ if (loginRes) { const userInfo = await sheep.$store('user').getInfo(); closeAuthModal(); - // 如果用户已经有头像和昵称,不要每次登录都要重新上传头像。 - if(userInfo.avatar && userInfo.nickname) return; - + // 如果用户已经有头像和昵称,不需要再次授权 + if (userInfo.avatar && userInfo.nickname) { + return; + } + // 触发小程序授权信息弹框 // #ifdef MP-WEIXIN showAuthModal('mpAuthorization');