mirror of
https://github.com/any86/any-rule.git
synced 2025-07-14 15:38:58 +08:00
fix: 精准"身份证号"的校验
This commit is contained in:
parent
9c37d56935
commit
f091e0dc7f
@ -77,7 +77,7 @@ module.exports = [{
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '身份证号(15位、18位数字),最后一位是校验位,可能为数字或字符X',
|
title: '身份证号(15位、18位数字),最后一位是校验位,可能为数字或字符X',
|
||||||
rule: /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/,
|
rule: /(^\d{6}\d{2}([0-1][0-2]|\d)([0-2]\d|30|31)\d{3}$)|(^\d{6}(18|19|20)\d{2}([0-1][0-2]|\d)([0-2]\d|30|31)\d{3}(\d|X|x)$)/,
|
||||||
example: '如: 622223199912051311'
|
example: '如: 622223199912051311'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user