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
4b3e7596
Commit
4b3e7596
authored
Mar 02, 2018
by
zhuwei
Committed by
hujun
Mar 05, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
后台-客户详情
parent
78fc8173
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
86 additions
and
0 deletions
+86
-0
Remark.php
application/index/controller/Remark.php
+82
-0
route.php
application/route.php
+4
-0
No files found.
application/index/controller/Remark.php
View file @
4b3e7596
...
...
@@ -9,7 +9,12 @@
namespace
app\index\controller
;
use
app\index\extend\Basic
;
use
app\model\Agents
;
use
app\model\GOperatingRecords
;
use
app\model\Remarks
;
use
app\model\ULabels
;
use
app\model\UPhoneFollowPp
;
use
app\model\Users
;
use
think\Session
;
class
Remark
extends
Basic
...
...
@@ -115,4 +120,80 @@ class Remark extends Basic
}
/**
* 客户动态展示加搜索加客户详情
*
* @return \think\Response
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException
*/
public
function
useraction_search
()
{
header
(
'Access-Control-Allow-Origin:*'
);
$params
=
$this
->
params
;
$params
[
'user_id'
]
=
'1'
;
// if (!isset($params['user_id'])) {
// return $this->response("300", "参数不全", [ 'remote_groupid' => '' ]);
// }
$searchdate
=
$params
[
'searchdate'
];
$pagenum
=
isset
(
$params
[
'pagenum'
])
?
$params
[
'pagenum'
]
:
1
;
$pagesize
=
15
;
$user_id
=
$params
[
'user_id'
];
$UPhoneFollowPp
=
new
UPhoneFollowPp
();
// 查询电话跟进数据
$UPhoneFollowPp_res
=
$UPhoneFollowPp
->
select_useraction_search
(
$user_id
,
$searchdate
);
//var_dump($UPhoneFollowPp_res);
/*dump($total);
var_dump($user_res);
exit;*/
//dump($UPhoneFollowPp_res);
foreach
(
$UPhoneFollowPp_res
as
$k
=>
$v
){
$table
=
new
Agents
();
$Agents_res
=
$table
->
Agents_res
(
$v
[
'agent_id'
]);
//dump($Agents_res);
$UPhoneFollowPp_res
[
$k
][
'agentinfo'
]
=
$Agents_res
?
$Agents_res
[
'agentshopname'
]
.
'-'
.
$Agents_res
[
'realname'
]
:
'未知'
;
$UPhoneFollowPp_res
[
$k
][
'user_pic'
]
=
ADMIN_URL_TL
.
'user_header/'
.
$Agents_res
[
'head_portrait'
];
$UPhoneFollowPp_res
[
$k
][
'label'
]
=
''
;
//dump($v['labels_id']);
//电话跟进标签
if
(
$v
[
'labels_id'
]){
$table
=
new
ULabels
();
$table_res
=
$table
->
get_labelsname
(
$v
[
'labels_id'
]);
//dump($table_res);
//exit;
$UPhoneFollowPp_res
[
$k
][
'label'
]
=
$table_res
[
0
][
'name'
];
}
}
if
(
$UPhoneFollowPp_res
)
{
$user
=
new
Users
();
$user_res
=
$user
->
useraction_search_user_res
(
$user_id
);
//dump($user_res);
$user_res
[
'user_pic'
]
=
HEADERIMGURL
.
$user_res
[
'user_pic'
];
$table
=
new
Agents
();
$Agents_res
=
$table
->
Agents_res
(
$v
[
'agent_id'
]);
//dump($Agents_res);
$user_res
[
'agentinfo'
]
=
$Agents_res
?
$Agents_res
[
'realname'
]
.
'/'
.
$Agents_res
[
'phone'
]
:
'未知'
;
$records
=
new
GOperatingRecords
();
$records_result
=
$records
->
user_history
(
$user_id
);
//dump($records_result);
//dump($user_id);
return
$this
->
response
(
"200"
,
"success!"
,
[
'user_info'
=>
$user_res
,
'user_date'
=>
$UPhoneFollowPp_res
,
'user_history'
=>
$records_result
]);
}
else
{
return
$this
->
response
(
"101"
,
"失败!"
);
}
}
}
\ No newline at end of file
application/route.php
View file @
4b3e7596
...
...
@@ -157,6 +157,10 @@ Route::group('index', [
'CellPhoneAgentIndex'
=>
[
'index/CellPhone/agentIndex'
,
[
'method'
=>
'get'
]
],
//经纪人通话列表
'phoneList'
=>
[
'index/Phone/phoneList'
,
[
'method'
=>
'get'
]
],
//号码池
'bindPhoneListIndex'
=>
[
'index/Phone/bindPhoneListIndex'
,
[
'method'
=>
'get'
]
],
//号码绑定列表
'useraction_search'
=>
[
'index/remark/useraction_search'
,
[
'method'
=>
'get|post'
]
],
//后台客户详情
]);
...
...
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