|
@@ -148,10 +148,14 @@ class TalentInfo extends Validate {
|
|
|
if (!preg_match("/^[a-zA-Z0-9]{6,10}$/", $value) && !preg_match("/^([0-9]{8}|[0-9]{10})$/", $value)) {
|
|
|
return "通行证号码不合法";
|
|
|
}
|
|
|
- } else {
|
|
|
+ } else if ($data["card_type"] == 3) {
|
|
|
if (!preg_match("/^([a-zA-z]|[0-9]){5,17}$/", $value)) {
|
|
|
return "护照号码不合法";
|
|
|
}
|
|
|
+ } else if ($data["card_type"] == 4) {
|
|
|
+ if (!preg_match("/^[1-9]\d{5}[0-9]{3}\d{3}[0-9Xx]$/", $value)) {
|
|
|
+ return "港澳居民居住证不合法";
|
|
|
+ }
|
|
|
}
|
|
|
$db = $this->db->name($rule);
|
|
|
$where = [];
|