|
@@ -45,7 +45,7 @@
|
|
|
<span class="title"><em class="fvx">*</em>身份证</span>
|
|
|
<input type="text" name="cardId" v-model="cardId" class="ui-ipt iptform" placeholder="输入证件号" clearable>
|
|
|
|
|
|
- <span class="formver ng-scope" v-if="cardId && cardId.length!=18">
|
|
|
+ <span class="formver ng-scope" v-if="!is_ok_card(cardId)">
|
|
|
<span class="p-ico ico-formver"></span>
|
|
|
<span class="p-ico ico-worm"></span>请输入18位身份证号
|
|
|
</span>
|
|
@@ -242,9 +242,15 @@
|
|
|
}
|
|
|
}, 1000)
|
|
|
},
|
|
|
+ is_ok_card( cardId ){
|
|
|
+ if( !cardId ) return false;
|
|
|
+ if( cardId.indexOf('H')>-1 || cardId.indexOf('W') >-1) return cardId.length ==11;
|
|
|
+ return cardId.length ==18;
|
|
|
+
|
|
|
+ },
|
|
|
cansubmit() {
|
|
|
if (this.isPhoneErr()) return false;
|
|
|
- if (this.cardId.length != 18) return false;
|
|
|
+ if (!this.is_ok_card(this.cardId)) return false;
|
|
|
if (!this.name) return false;
|
|
|
if (!this.password || this.password != this.confirmPassword) return false;
|
|
|
if (this.password.length < 6) return false;
|