sl-express/project-wl-yonghuduan-uniapp-vue3/unpackage/dist/dev/mp-weixin/utils/validate.js

13 lines
317 B
JavaScript
Raw Normal View History

2023-09-04 16:40:17 +08:00
"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;