From 100eca8176c938ab9bf3d8f6e7fac59a0a7f3834 Mon Sep 17 00:00:00 2001 From: TM <923727421@qq.com> Date: Tue, 15 Dec 2020 20:10:03 +0800 Subject: [PATCH] 添加限制 --- pages/hbfqPage/orderInfo/orderInfo.js | 16 ++++++++++++++++ 1 files changed, 16 insertions(+), 0 deletions(-) diff --git a/pages/hbfqPage/orderInfo/orderInfo.js b/pages/hbfqPage/orderInfo/orderInfo.js index 89702f6..54fbcda 100644 --- a/pages/hbfqPage/orderInfo/orderInfo.js +++ b/pages/hbfqPage/orderInfo/orderInfo.js @@ -250,6 +250,14 @@ }); return } + if (!validator.checkPhone(info.userMblNo)) { + my.showToast({ + type: 'none', + content: '请输入正确的客户手机号', + duration: 2000, + }); + return + } my.scan({ scanType: ['qrCode', 'barCode'], success: (res) => { @@ -343,6 +351,14 @@ }); return } + if (!validator.checkPhone(info.userMblNo)) { + my.showToast({ + type: 'none', + content: '请输入正确的客户手机号', + duration: 2000, + }); + return + } let str = JSON.stringify(this.data.info) my.navigateTo({ url: `../qrCode/qrCode?info=${str}` -- Gitblit v1.8.0