From 8c6585a3dcb44cc82a7ac1bca5e27eb7910fc47a Mon Sep 17 00:00:00 2001
From: liruiqiang <3151805288@qq.com>
Date: Tue, 19 Aug 2025 14:38:37 +0800
Subject: [PATCH] =?UTF-8?q?=E5=BE=AE=E4=BF=A1=E7=99=BB=E5=BD=95=EF=BC=88?=
=?UTF-8?q?=E6=A8=A1=E6=8B=9F=EF=BC=89?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/pages/login/login.vue | 10 ++++++++--
src/services/login.ts | 15 +++++++++++++++
2 files changed, 23 insertions(+), 2 deletions(-)
diff --git a/src/pages/login/login.vue b/src/pages/login/login.vue
index 2de2c10..6a040d5 100644
--- a/src/pages/login/login.vue
+++ b/src/pages/login/login.vue
@@ -23,7 +23,7 @@
@@ -50,10 +50,16 @@ const onGetphonenumber: UniHelper.ButtonOnGetphonenumber = async (ev) => {
const encryptedData = ev.detail.encryptedData!
const iv = ev.detail.iv!
// 登录请求
- await postLoginWxMinAPI({ code, encryptedData, iv })
+ const res = await postLoginWxMinAPI({ code, encryptedData, iv })
// 成功提示
uni.showToast({ icon: 'none', title: '登录成功' })
}
+
+// 模拟手机号码快捷登录(开发练习)
+const onGetphonenumberSimple = async () => {
+ const res = await postLoginWxMinSimpleAPI('18730880302')
+ uni.showToast({ icon: 'none', title: '登录成功' })
+}