From f67e6a7f5499538f2d942cba70973edb6e07195b Mon Sep 17 00:00:00 2001 From: YunaiV Date: Thu, 25 Jul 2024 08:48:45 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E4=BB=A3=E7=A0=81=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E3=80=91login.vue=20=E5=BE=AE=E4=BF=A1=E7=99=BB=E5=BD=95?= =?UTF-8?q?=E7=BB=91=E5=AE=9A=E8=BF=87=E6=85=A2=EF=BC=8C=E5=AF=BC=E8=87=B4?= =?UTF-8?q?=E7=99=BB=E5=BD=95=E5=A4=B1=E8=B4=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/index/login.vue | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pages/index/login.vue b/pages/index/login.vue index b2c82a4a..e4988702 100644 --- a/pages/index/login.vue +++ b/pages/index/login.vue @@ -14,13 +14,14 @@ new URLSearchParams(location.search).forEach((value, key) => { options[key] = value; }); + // 执行登录 or 绑定,注意需要 await 绑定 const event = options.event; const code = options.code; const state = options.state; if (event === 'login') { // 场景一:登录 - const res = await sheep.$platform.useProvider().login(code, state); + await sheep.$platform.useProvider().login(code, state); } else if (event === 'bind') { // 场景二:绑定 - sheep.$platform.useProvider().bind(code, state); + await sheep.$platform.useProvider().bind(code, state); } // 检测 H5 登录回调