Commit 4726fc96 authored by zhuwei's avatar zhuwei

bug

parent 0cfde2d2
......@@ -67,8 +67,8 @@ class HomePageLog extends Basic
}
if (!empty($params["name_or_phone"])) {
if ((preg_match("/^1\d{10}$/", $params['name_or_phone']) != 1) or (strlen($params['name_or_phone']) < 6)) {
return $this->response("300", '手机号有误或者姓名不满两位汉字');
if ((preg_match("/^1\d{10}$/", $params['name_or_phone']) != 1) and (strlen($params['name_or_phone']) < 6)) {
return $this->response("101", '手机号有误或者姓名不满两位汉字');
}
$agent_params["phone|name"] = $params["name_or_phone"];
$agent_field = "id";
......@@ -168,8 +168,8 @@ class HomePageLog extends Basic
if (!empty($params["name_or_phone"])) {
if ((preg_match("/^1\d{10}$/", $params['name_or_phone']) != 1) or (strlen($params['name_or_phone']) < 6)) {
return $this->response("300", '手机号有误或者姓名不满两位汉字');
if ((preg_match("/^1\d{10}$/", $params['name_or_phone']) != 1) and (strlen($params['name_or_phone']) < 6)) {
return $this->response("101", '手机号有误或者姓名不满两位汉字');
}
//$agent_params["phone|name"] = array( "like", "%" . trim($params["name_or_phone"]) . "%" );
$agent_params["phone|name"] = $params["name_or_phone"];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment