提交 5b83dcf3f769ac898ce2fca1301f581ed1bcf25c

作者 pangy
2 个父辈 814be092 48007ae6

Merge branch 'dev_py' into dev2.0

... ... @@ -252,13 +252,7 @@ Page({
252 252 var formdata = e.detail.value;
253 253 console.log("formdata", formdata);
254 254 console.log('idnum', this.data.card_number.length < 1 && !format.isIDCardNum(formdata.id_card_no))
255   - if (formdata.name.length < 1) {
256   - this.showtoast('姓名未填写');
257   - return
258   - } else if (!regname.test(formdata.name)) {
259   - this.showtoast('请输入正确姓名');
260   - return
261   - } else if (this.data.relativeData.selected.length < 1) {
  255 + if (this.data.relativeData.selected.length < 1) {
262 256 this.showtoast('请选择关系');
263 257 return
264 258 }
... ... @@ -272,8 +266,11 @@ Page({
272 266 this.showtoast('请填写证照号码');
273 267 return
274 268 }
275   - else if (formdata.email && formdata.email.length > 0 && !regEmail.test(formdata.email)) {
276   - this.showtoast('请输入正确邮箱');
  269 + if (formdata.name.length < 1) {
  270 + this.showtoast('姓名未填写');
  271 + return
  272 + } else if (!regname.test(formdata.name)) {
  273 + this.showtoast('请输入正确姓名');
277 274 return
278 275 }
279 276 var new_card_num = ''
... ...
注册登录 后发表评论