sl-express/project-wl-yonghuduan-uniapp-vue3/unpackage/dist/dev/mp-weixin/utils/validate.js
shuhongfan cf5ac25c14 init
2023-09-04 16:40:17 +08:00

13 lines
317 B
JavaScript

"use strict";
const validateIdentityCard = (value) => {
const accountreg = /(^\d{15}$)|(^\d{17}(\d|X|x)$)/g;
if (value === void 0 || value === "") {
return false;
} else if (!accountreg.test(value)) {
return false;
} else {
return true;
}
};
exports.validateIdentityCard = validateIdentityCard;