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
f9e41b88
Commit
f9e41b88
authored
Sep 14, 2018
by
clone
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
a3bdedd2
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
4 deletions
+12
-4
User.php
application/api_broker/controller/User.php
+12
-4
No files found.
application/api_broker/controller/User.php
View file @
f9e41b88
...
@@ -94,17 +94,21 @@ class User extends Basic
...
@@ -94,17 +94,21 @@ class User extends Basic
if
(
isset
(
$params
[
'user_status'
]))
{
if
(
isset
(
$params
[
'user_status'
]))
{
$conditions
[
'user_status'
]
=
$params
[
'user_status'
];
$conditions
[
'user_status'
]
=
$params
[
'user_status'
];
}
}
$is_search
=
false
;
if
(
isset
(
$params
[
'id'
]))
{
if
(
isset
(
$params
[
'id'
]))
{
$conditions
[
'id'
]
=
$params
[
'id'
];
$conditions
[
'id'
]
=
$params
[
'id'
];
$is_search
=
true
;
}
}
if
(
isset
(
$params
[
'user_name'
]))
{
if
(
isset
(
$params
[
'user_name'
]))
{
$conditions
[
'user_name'
]
=
array
(
"like"
,
"%"
.
trim
(
$params
[
'user_name'
])
.
"%"
);
$conditions
[
'user_name'
]
=
array
(
"like"
,
"%"
.
trim
(
$params
[
'user_name'
])
.
"%"
);
$is_search
=
true
;
}
}
if
(
isset
(
$params
[
'user_phone'
]))
{
if
(
isset
(
$params
[
'user_phone'
]))
{
$conditions
[
'user_phone'
]
=
array
(
"like"
,
"%"
.
trim
(
$params
[
'user_phone'
])
.
"%"
);
$conditions
[
'user_phone'
]
=
array
(
"like"
,
"%"
.
trim
(
$params
[
'user_phone'
])
.
"%"
);
$is_search
=
true
;
}
}
if
(
isset
(
$params
[
'yetai'
]))
{
if
(
isset
(
$params
[
'yetai'
]))
{
...
@@ -146,6 +150,10 @@ class User extends Basic
...
@@ -146,6 +150,10 @@ class User extends Basic
$conditions
[
'agent_id'
]
=
$params
[
'agent_id'
];
$conditions
[
'agent_id'
]
=
$params
[
'agent_id'
];
}
}
if
(
!
$is_search
)
{
$conditions
[
'user_label'
]
=
array
(
"neq"
,
2
);
}
$userList
=
$this
->
userModel
->
selectUserList
(
$field
,
$conditions
,
$pageNo
,
$pageSize
,
"id desc"
);
$userList
=
$this
->
userModel
->
selectUserList
(
$field
,
$conditions
,
$pageNo
,
$pageSize
,
"id desc"
);
//dump($userList);
//dump($userList);
if
(
empty
(
$userList
))
{
if
(
empty
(
$userList
))
{
...
@@ -624,12 +632,12 @@ class User extends Basic
...
@@ -624,12 +632,12 @@ class User extends Basic
// 判断当天被拨打是否超过5次
// 判断当天被拨打是否超过5次
$model_agent
=
new
AAgents
();
$model_agent
=
new
AAgents
();
$result
=
$model_agent
->
searchAgentsByKeyword
(
"id,name,phone"
,
[
"id"
=>
$params
[
"agent_id"
]
]);
$result
=
$model_agent
->
searchAgentsByKeyword
(
"id,name,phone"
,
[
"id"
=>
$params
[
"agent_id"
]
]);
$call
=
new
CallPhoneService
();
$call
=
new
CallPhoneService
();
$gresult
=
$call
->
getBindNum
(
$model_res
[
'user_phone'
],
$result
[
0
][
'phone'
]);
$gresult
=
$call
->
getBindNum
(
$model_res
[
'user_phone'
],
$result
[
0
][
'phone'
]);
$clientService
=
new
ClientService
();
$clientService
=
new
ClientService
();
if
(
!
$clientService
->
dialTotal
(
$model_res
[
0
][
'user_id'
])
&&
$gresult
==
0
)
{
if
(
!
$clientService
->
dialTotal
(
$model_res
[
0
][
'user_id'
])
&&
$gresult
==
0
)
{
return
$this
->
response
(
"201"
,
"当天被拨打超过5次"
,
[
'id'
=>
$model_res
[
0
][
'id'
]
]);
return
$this
->
response
(
"201"
,
"当天被拨打超过5次"
,
[
'id'
=>
$model_res
[
0
][
'id'
]
]);
}
}
//如果非客方
//如果非客方
...
...
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