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
0a7b63cf
Commit
0a7b63cf
authored
Oct 22, 2018
by
zhuwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
设置用户站点 报备
parent
c0cdbfc8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
Report.php
application/api_broker/controller/Report.php
+7
-1
No files found.
application/api_broker/controller/Report.php
View file @
0a7b63cf
...
...
@@ -4,6 +4,7 @@ namespace app\api_broker\controller;
use
app\api_broker\extend\Basic
;
use
app\api_broker\service\ReportService
;
use
app\index\service\UserService
;
use
app\model\AAgents
;
use
app\model\FollowUpLogModel
;
use
app\model\GHousesToAgents
;
...
...
@@ -21,6 +22,7 @@ class Report extends Basic
{
private
$service_
;
private
$fulModel
;
private
$userService
;
public
function
__construct
(
$request
=
null
)
...
...
@@ -28,6 +30,8 @@ class Report extends Basic
parent
::
__construct
(
$request
);
$this
->
service_
=
new
ReportService
();
$this
->
fulModel
=
new
FollowUpLogModel
();
$this
->
userService
=
new
UserService
();
}
...
...
@@ -39,7 +43,7 @@ class Report extends Basic
{
$params
=
$this
->
params
;
if
(
!
isset
(
$params
[
'report_agent_id'
])
||
!
isset
(
$params
[
'report_agent_phone'
])
||
!
isset
(
$params
[
'report_store_id'
])
||
!
isset
(
$params
[
'user_id'
])
||
!
isset
(
$params
[
'house_ids'
])
||
!
isset
(
$params
[
'vehicle'
]))
{
!
isset
(
$params
[
'house_ids'
])
||
!
isset
(
$params
[
'vehicle'
])
||
!
isset
(
$params
[
'site_id'
])
)
{
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
...
...
@@ -64,6 +68,7 @@ class Report extends Basic
$vehicle
=
$params
[
"vehicle"
];
$intro
=
$params
[
"intro"
];
$predict_see_time
=
$params
[
"predict_see_time"
];
$site_id
=
$params
[
"site_id"
];
//todo 验证用户id是否正常
$userArr
=
$this
->
service_
->
verifyUser
(
$user_id
);
...
...
@@ -73,6 +78,7 @@ class Report extends Basic
$is_ok
=
$this
->
service_
->
verifyReport
(
$agent_id
,
$agent_phone
,
$this
->
agentName
,
$store_id
,
$user_id
,
$userArr
[
"user_phone"
],
$userArr
[
"user_name"
],
$house_ids
,
$vehicle
,
$intro
,
$predict_see_time
);
if
(
$is_ok
>
0
)
{
$this
->
userService
->
setUserSites
(
$user_id
,
$site_id
);
//设置用户站点 朱伟 2018-10-22
return
$this
->
response
(
"200"
,
"request success"
,
[]);
}
else
{
return
$this
->
response
(
"101"
,
"save exception"
);
...
...
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