Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tl_estate
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hujun
tl_estate
Commits
2939348c
Commit
2939348c
authored
Aug 15, 2018
by
zhuwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
00a70345
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
HomePageLog.php
application/api_broker/controller/HomePageLog.php
+9
-3
No files found.
application/api_broker/controller/HomePageLog.php
View file @
2939348c
...
@@ -70,12 +70,16 @@ class HomePageLog extends Basic
...
@@ -70,12 +70,16 @@ class HomePageLog extends Basic
if
((
preg_match
(
"/^1\d
{
10
}
$/"
,
$params
[
'name_or_phone'
])
!=
1
)
and
(
strlen
(
$params
[
'name_or_phone'
])
<
6
))
{
if
((
preg_match
(
"/^1\d
{
10
}
$/"
,
$params
[
'name_or_phone'
])
!=
1
)
and
(
strlen
(
$params
[
'name_or_phone'
])
<
6
))
{
return
$this
->
response
(
"101"
,
'手机号有误或者姓名不满两位汉字'
);
return
$this
->
response
(
"101"
,
'手机号有误或者姓名不满两位汉字'
);
}
}
$agent_params
[
"phone|name"
]
=
$params
[
"name_or_phone"
];
// $agent_params["phone|name"] = $params["name_or_phone"];
$agent_params
[
"phone|name"
]
=
array
(
"like"
,
"%"
.
trim
(
$params
[
"name_or_phone"
])
.
"%"
);
$agent_field
=
"id"
;
$agent_field
=
"id"
;
$model
=
new
AAgents
();
$model
=
new
AAgents
();
$res_a
=
$model
->
getAgentsIdsArray
(
$agent_field
,
$agent_params
);
$res_a
=
$model
->
getAgentsIdsArray
(
$agent_field
,
$agent_params
);
if
(
$res_a
)
{
if
(
$res_a
)
{
$where_
[
"f.agent_id"
]
=
[
'in'
,
$res_a
];
$where_
[
"f.agent_id"
]
=
[
'in'
,
$res_a
];
}
else
{
return
$this
->
response
(
"200"
,
"request null"
);
}
}
}
}
...
@@ -171,13 +175,15 @@ class HomePageLog extends Basic
...
@@ -171,13 +175,15 @@ class HomePageLog extends Basic
if
((
preg_match
(
"/^1\d
{
10
}
$/"
,
$params
[
'name_or_phone'
])
!=
1
)
and
(
strlen
(
$params
[
'name_or_phone'
])
<
6
))
{
if
((
preg_match
(
"/^1\d
{
10
}
$/"
,
$params
[
'name_or_phone'
])
!=
1
)
and
(
strlen
(
$params
[
'name_or_phone'
])
<
6
))
{
return
$this
->
response
(
"101"
,
'手机号有误或者姓名不满两位汉字'
);
return
$this
->
response
(
"101"
,
'手机号有误或者姓名不满两位汉字'
);
}
}
//
$agent_params["phone|name"] = array( "like", "%" . trim($params["name_or_phone"]) . "%" );
$agent_params
[
"phone|name"
]
=
array
(
"like"
,
"%"
.
trim
(
$params
[
"name_or_phone"
])
.
"%"
);
$agent_params
[
"phone|name"
]
=
$params
[
"name_or_phone"
];
//
$agent_params["phone|name"] = $params["name_or_phone"];
$agent_field
=
"id"
;
$agent_field
=
"id"
;
$model
=
new
AAgents
();
$model
=
new
AAgents
();
$res_a
=
$model
->
getAgentsIdsArray
(
$agent_field
,
$agent_params
);
$res_a
=
$model
->
getAgentsIdsArray
(
$agent_field
,
$agent_params
);
if
(
$res_a
)
{
if
(
$res_a
)
{
$where_
[
"f.agent_id"
]
=
[
'in'
,
$res_a
];
$where_
[
"f.agent_id"
]
=
[
'in'
,
$res_a
];
}
else
{
return
$this
->
response
(
"200"
,
"request null"
);
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment