修复了验证码bug
This commit is contained in:
@ -54,7 +54,7 @@ Page({
|
||||
},
|
||||
|
||||
sendSmsCode() {
|
||||
const { phone } = this.data;
|
||||
const { phone, role } = this.data;
|
||||
if (!phone.trim()) {
|
||||
wx.showToast({ title: '请输入手机号', icon: 'none' });
|
||||
return;
|
||||
@ -68,7 +68,8 @@ Page({
|
||||
method: 'POST',
|
||||
header: { 'content-type': 'application/json' },
|
||||
data: {
|
||||
templateString: phone
|
||||
phoneNumber: phone,
|
||||
userRole: role
|
||||
},
|
||||
success: res => {
|
||||
// 假设后端返回 { success: true, ... }
|
||||
|
Reference in New Issue
Block a user