Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
data-table
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
hookehuyr
2024-08-23 13:51:35 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
a60aff28cb250a2bb0830f081403b74ca4a6c841
a60aff28
1 parent
fd86457a
fix 默认值是加密模式,跳过校验
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
src/components/IdentityField/index.vue
src/components/IdentityField/index.vue
View file @
a60aff2
<!--
* @Date: 2022-09-14 14:44:30
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2024-08-23 13:
39:19
* @LastEditTime: 2024-08-23 13:
51:02
* @FilePath: /data-table/src/components/IdentityField/index.vue
* @Description: 身份证输入控件
-->
...
...
@@ -183,10 +183,13 @@ var checkCode = function (val) {
const idCard = {
verify: function (val) {
if(checkCode(val)) {
if (val.indexOf('*') !== -1) { // 默认值是加密模式,跳过校验
return true;
}
if (checkCode(val)) {
var date = val.substring(6,14);
if(checkDate(date)) {
if(checkProv(val.substring(0,2))) {
if
(checkDate(date)) {
if
(checkProv(val.substring(0,2))) {
return true;
}
}
...
...
Please
register
or
login
to post a comment