|
|
@@ -172,10 +172,13 @@ Page({ |
|
|
|
}, |
|
|
|
|
|
|
|
getCouponOrderByPassword(password) { |
|
|
|
const that = this |
|
|
|
Http.post({ |
|
|
|
url: config.api.getCouponOrderByPassword, |
|
|
|
data: { |
|
|
|
password, |
|
|
|
payCheck: that.data.pdwSwitch, |
|
|
|
payPassword: that.data.password |
|
|
|
} |
|
|
|
}) |
|
|
|
.then(res => { |
|
|
@@ -217,6 +220,26 @@ Page({ |
|
|
|
}, |
|
|
|
|
|
|
|
submit() { |
|
|
|
if (this.data.pdwSwitch) { |
|
|
|
const password = this.data.password |
|
|
|
const numReg = /^\d+$/ |
|
|
|
|
|
|
|
if (!password) { |
|
|
|
wx.showToast({ |
|
|
|
title: '密码不能为空!', |
|
|
|
icon: 'none' |
|
|
|
}) |
|
|
|
return |
|
|
|
} |
|
|
|
|
|
|
|
if (!numReg.test(password) || password.length != 6) { |
|
|
|
wx.showToast({ |
|
|
|
title: '密码只能为6位数字!', |
|
|
|
icon: 'none' |
|
|
|
}) |
|
|
|
return |
|
|
|
} |
|
|
|
} |
|
|
|
const e = { |
|
|
|
detail: { value: { code: this.data.code } } |
|
|
|
} |
|
|
|