From 154bcf7d7c3f5b2ec85131f928d3b5766ea9bb88 Mon Sep 17 00:00:00 2001 From: rosehan <151435705@qq.com> Date: Thu, 17 Aug 2023 17:59:03 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A2=84=E7=BA=A68-17?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- static/ancss/an.css | 2 +- .../scenic/subscribe/yuyue/yue_detail_js.vue | 2 +- .../scenic/subscribe/yuyue/yue_form_js.vue | 26 ++++++++++++++++--- 3 files changed, 25 insertions(+), 5 deletions(-) diff --git a/static/ancss/an.css b/static/ancss/an.css index 9c5f46c..d5b911e 100644 --- a/static/ancss/an.css +++ b/static/ancss/an.css @@ -674,7 +674,7 @@ s首页菜单 .wei_box, .huan_box, .guo_box{position: absolute; width: 100%; left: 0; top:0; height: 400rpx; background: #fe9900; z-index: 0;} .huan_box{background: #22b938;} .guo_box{background: #007AFF;} -.yuyue-btn{position: fixed; bottom: 0;left: 0; width: 100%;background-color: #F5F5F5; } +.yuyue-btn{position: fixed;z-index: 9999; bottom: 0;left: 0; width: 100%;background-color: #F5F5F5; } .yuyue-btn .an_box_2{} .add_btn{height: 60rpx;line-height: 60rpx;font-size: 32rpx; background: #d9e7ff; diff --git a/sunPackIndex/scenic/subscribe/yuyue/yue_detail_js.vue b/sunPackIndex/scenic/subscribe/yuyue/yue_detail_js.vue index de6fa78..4ca39de 100644 --- a/sunPackIndex/scenic/subscribe/yuyue/yue_detail_js.vue +++ b/sunPackIndex/scenic/subscribe/yuyue/yue_detail_js.vue @@ -64,7 +64,7 @@ - diff --git a/sunPackIndex/scenic/subscribe/yuyue/yue_form_js.vue b/sunPackIndex/scenic/subscribe/yuyue/yue_form_js.vue index de2b2c3..f32c07e 100644 --- a/sunPackIndex/scenic/subscribe/yuyue/yue_form_js.vue +++ b/sunPackIndex/scenic/subscribe/yuyue/yue_form_js.vue @@ -28,6 +28,7 @@ + 请填写正确的身份证件号码 @@ -168,6 +169,7 @@ phone: "", documentsType: '5501', idCardNumber: "", + idCardState: false, passportNumber: "", } //判断最多预约人数 @@ -192,9 +194,21 @@ let state = [] that.dynamicLists.map((item, index) => { that.$refs.form[index].validate().then(res => { - state[index] = '1' + + + let idreg = + /^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}([0-9]|X)$/; + if (!idreg.test(item.idCardNumber)) { + state[index] = '0' + that.dynamicLists[index].idCardState=true + } else { + state[index] = '1' + that.dynamicLists[index].idCardState=false + } + }).catch(err => { state[index] = '0' + that.dynamicLists[index].idCardState=false }) }) setTimeout(function() { @@ -207,13 +221,11 @@ }, 1000); }) - promise.then(value => { if (value == 'success') { this.postReserve() } }) - }, //传输数据 postReserve: function() { @@ -313,4 +325,12 @@ .yue_xuzhi text { color: rgb(22, 119, 255); } + .v-form-tip{color: #f56c6c; + font-size: 12px; + line-height: 1; + padding-top: 4px; + position: absolute; + top: 5px; + left: 0; + } \ No newline at end of file