diff --git a/pages/user/userinfo/userinfo.js b/pages/user/userinfo/userinfo.js index f0361d6..faa392d 100644 --- a/pages/user/userinfo/userinfo.js +++ b/pages/user/userinfo/userinfo.js @@ -741,26 +741,23 @@ Page({ var identity_card = th.data.identity_card;//身份证 console.log("身份证",identity_card); - if (identity_card == "" || identity_card == null ) { - getApp().my_warnning("请输入身份证", 0, th); - return false; - } else if (!(/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/.test(identity_card))){ + if (identity_card != "" && !(/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/.test(identity_card))){ getApp().my_warnning("身份证号码错误",0, th); return false; } var address = th.data.address;//地址 - console.log("地址1010101", address) - if (address == "" || address == null) { - getApp().my_warnning("请输入地址", 0, th); - return false; - } + // console.log("地址1010101", address) + // if (address == "" || address == null) { + // getApp().my_warnning("请输入地址", 0, th); + // return false; + // } //保存所属门店的id var sto_sele_id=th.data.sto_sele_id; - console.log("请输入所属门店的id", sto_sele_id); - if (sto_sele_id == null || sto_sele_id==""){ - getApp().my_warnning("请输入所属门店", 0, th); - return false; - } + // console.log("请输入所属门店的id", sto_sele_id); + // if (sto_sele_id == null || sto_sele_id==""){ + // getApp().my_warnning("请输入所属门店", 0, th); + // return false; + // } console.log("要保存的数据", sex, consumption, identity_card, address, user_name); var datas = { mobile: phone,//手机号码