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
571db288
Commit
571db288
authored
Mar 01, 2018
by
zw
Committed by
hujun
Mar 05, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
报备列表
parent
72ece921
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
81 additions
and
1 deletion
+81
-1
Report.php
application/api_broker/controller/Report.php
+36
-0
Shop.php
application/api_broker/controller/Shop.php
+1
-1
OReportModel.php
application/model/OReportModel.php
+23
-0
route.php
application/route.php
+21
-0
No files found.
application/api_broker/controller/Report.php
View file @
571db288
...
...
@@ -5,6 +5,7 @@ namespace app\api_broker\controller;
use
app\api_broker\extend\Basic
;
use
app\api_broker\service\ReportService
;
use
app\model\FollowUpLogModel
;
use
app\model\OReportModel
;
use
think\Exception
;
/**
...
...
@@ -18,12 +19,14 @@ class Report extends Basic
{
private
$service_
;
private
$fulModel
;
private
$oReportModel
;
public
function
__construct
(
$request
=
null
)
{
parent
::
__construct
(
$request
);
$this
->
service_
=
new
ReportService
();
$this
->
fulModel
=
new
FollowUpLogModel
();
$this
->
oReportModel
=
new
OReportModel
();
}
/**
...
...
@@ -76,6 +79,39 @@ class Report extends Basic
}
/**
* 获取报备列表
* @return \think\Response
*/
public
function
reportList
(){
/* $params = array(
"agent_id" =>1,
);*/
$params
=
$this
->
params
;
if
(
!
isset
(
$params
[
"agent_id"
])){
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
$field
=
"a.id,a.user_id,a.user_phone,a.user_name,a.predict_see_time,b.house_id,b.house_title"
;
$params
[
"report_agent_id"
]
=
$params
[
"agent_id"
];
$result
=
$this
->
oReportModel
->
selectReportList
(
$field
,
$params
);
if
(
count
(
$result
)
>
0
){
foreach
(
$result
as
$k
=>
$v
){
$result
[
$k
][
"user_phone"
]
=
preg_replace
(
'/(\d{3})\d{4}(\d{4})/'
,
'$1****$2'
,
$v
[
"user_phone"
]);
}
}
return
$this
->
response
(
"200"
,
"request success"
,
$result
);
}
/**
* 新增跟进
...
...
application/api_broker/controller/Shop.php
View file @
571db288
...
...
@@ -216,7 +216,7 @@ class Shop extends Basic
if
(
$params
[
'site_area'
]
==
1
&&
isset
(
$params
[
'user_id'
]))
{
$attention
[
"user_id"
]
=
array
(
"eq"
,
$params
[
'user_id'
]
);
$attention
[
"house_id"
]
=
array
(
"eq"
,
$params
[
"id"
]
);
$attention
[
"is_del"
]
=
array
(
"eq"
,
0
);
;
$attention
[
"is_del"
]
=
array
(
"eq"
,
0
);
$attResult
=
$this
->
attentionModel
->
getAttentionByUserIdAndHouseId
(
$attention
);
if
(
count
(
$attResult
)
>
0
)
$result
[
"attention"
]
=
$attResult
[
"id"
];
...
...
application/model/OReportModel.php
View file @
571db288
...
...
@@ -72,4 +72,26 @@ class OReportModel extends Model
->
where
(
$where_
)
->
select
();
}
/**
* @param string $filed
* @param $params
* @return false|\PDOStatement|string|\think\Collection
*/
public
function
selectReportList
(
$filed
=
"id"
,
$params
){
$where_
=
[];
if
(
isset
(
$params
[
"report_agent_id"
]))
{
$where_
[
"a.report_agent_id"
]
=
$params
[
"report_agent_id"
];
}
$where_
[
"a.status"
]
=
0
;
$where_
[
"b.is_del"
]
=
0
;
return
$this
->
db
->
field
(
$filed
)
->
alias
(
"a"
)
->
join
(
"o_order b"
,
"a.id= b.f_id"
,
"left"
)
->
where
(
$where_
)
->
select
();
}
}
\ No newline at end of file
application/route.php
View file @
571db288
...
...
@@ -248,6 +248,27 @@ Route::group('broker', [
'collectingBill'
=>
[
'api_broker/OrderLog/collectingBill'
,
[
'method'
=>
'get|post'
]
],
'refund'
=>
[
'api_broker/OrderLog/refund'
,
[
'method'
=>
'get|post'
]
],
'bargain'
=>
[
'api_broker/OrderLog/bargain'
,
[
'method'
=>
'get|post'
]
],
'statusBargain'
=>
[
'api_broker/OrderLog/statusBargain'
,
[
'method'
=>
'get|post'
]
],
'login'
=>
[
'api_broker/Broker/login'
,
[
'method'
=>
'post'
]
],
//经纪人登陆
'editAgent'
=>
[
'api_broker/Broker/editAgent'
,
[
'method'
=>
'post'
]
],
//经纪人修改密码
'uploadHeadImg'
=>
[
'api_broker/Broker/uploadHeadImg'
,
[
'method'
=>
'post'
]
],
//经纪人上传头像
'editClient'
=>
[
'api_broker/Client/editClient'
,
[
'method'
=>
'get|post'
]
],
//添加和编辑客户
'getBroker'
=>
[
'api_broker/broker/getBroker'
,[
'method'
=>
'get'
]],
//获取经纪人列表
'labelEdit'
=>
[
'api_broker/label/index'
,[
'method'
=>
'get|post'
]],
//编辑标签
'getLabelsList'
=>
[
'api_broker/label/getLabelsList'
,[
'method'
=>
'get'
]],
//标签列表
'add_phone_follow_up'
=>
[
'api_broker/broker/add_phone_follow_up'
,[
'method'
=>
'get|post'
]],
//新增-客户电话跟进
'useraction_search'
=>
[
'api_broker/broker/useraction_search'
,[
'method'
=>
'get|post'
]],
//新增-客户电话跟进
'user_search'
=>
[
'api_broker/broker/user_search'
,[
'method'
=>
'get|post'
]],
//客户搜索
'bindAXB'
=>
[
'api_broker/CellPhone/bindAXB'
,
[
'method'
=>
'post'
]
],
//隐私号码
'agentsUnBind'
=>
[
'api_broker/CellPhone/agentsUnBind'
,
[
'method'
=>
'post'
]
],
//解除绑定关系
'updateBindAXB'
=>
[
'api_broker/CellPhone/updateBindAXB'
,
[
'method'
=>
'post'
]
],
//更新绑定关系隐私号码
//商铺
'getShopList'
=>
[
'api_broker/Shop/getShopList'
,
[
'method'
=>
'get|post'
]
],
'getShopDetail'
=>
[
'api_broker/Shop/getShopDetail'
,
[
'method'
=>
'get'
]
],
'reportList'
=>
[
'api_broker/Report/reportList'
,
[
'method'
=>
'get'
]
],
]);
Route
::
group
(
'task'
,[
...
...
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