瀏覽代碼

说明:绑定模态框,隐藏逻辑修复。

程志平 4 年之前
父節點
當前提交
c4995e667e
共有 1 個文件被更改,包括 3 次插入4 次删除
  1. 3 4
      pages/index/index.vue

+ 3 - 4
pages/index/index.vue

@@ -25,7 +25,7 @@
 				</view>
 				<view class="lineGroup-model">
 					<text class="iconfont icon-cardid label-icon-model"></text>
-					<input type='number' class="input-model" maxlength="18" placeholder="请输入身份证号码" v-model="id_card" />
+					<input type='text' class="input-model" maxlength="18" placeholder="请输入身份证号码" v-model="id_card" />
 				</view>
 				<view class="btn-model">
 					<button class="btn" @tap="confirmPop">绑定</button>
@@ -91,7 +91,6 @@
 			 */
 			confirmPop() { // 确认
 				if (this.stu_number.length == 14 && this.id_card.length == 18) {
-					this.showPop = false
 					// 获得code
 					this.getCode('confirm')
 				} else {
@@ -154,13 +153,13 @@
 						title: '用户绑定成功!',
 						icon: 'success'
 					});
+					
+					this.showPop = false
 				} else {
 					uni.showToast({
 						title: res.data.mess,
 						icon: 'success'
 					});
-					
-					this.showPop = true
 				}
 			},
 			/**