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
d5f2d6ba
Commit
d5f2d6ba
authored
Apr 09, 2018
by
clone
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
cb0ed964
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
10 deletions
+13
-10
OrderLog.php
application/api_broker/controller/OrderLog.php
+6
-5
OrderLogService.php
application/api_broker/service/OrderLogService.php
+7
-5
No files found.
application/api_broker/controller/OrderLog.php
View file @
d5f2d6ba
...
...
@@ -44,7 +44,7 @@ class OrderLog extends Basic
$params
=
$this
->
params
;
if
(
!
isset
(
$params
[
"march_in_area"
])
||
!
isset
(
$params
[
"report_id"
])
||
!
isset
(
$params
[
"reception_id"
])
||
!
isset
(
$params
[
"order_id"
])
||
!
isset
(
$params
[
"order_no"
]))
{
||
!
isset
(
$params
[
"
reception_name"
])
||
!
isset
(
$params
[
"
order_id"
])
||
!
isset
(
$params
[
"order_no"
]))
{
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
...
...
@@ -166,13 +166,14 @@ class OrderLog extends Basic
{
$params
=
$this
->
params
;
if
(
!
isset
(
$params
[
"submit_agent_id"
])
||
!
isset
(
$params
[
"report_id"
])
||
!
isset
(
$params
[
"order_id"
])
||
!
isset
(
$params
[
"order_no"
])
||
!
isset
(
$params
[
"trade_type"
])
||
!
isset
(
$params
[
"price"
])
||
!
isset
(
$params
[
"commission"
])
||
!
isset
(
$params
[
"commission_arr"
]))
{
if
(
!
isset
(
$params
[
"submit_agent_id"
])
||
!
isset
(
$params
[
"submit_agent_name"
])
||
!
isset
(
$params
[
"report_id"
])
||
!
isset
(
$params
[
"order_id"
])
||
!
isset
(
$params
[
"order_no"
])
||
!
isset
(
$params
[
"trade_type"
])
||
!
isset
(
$params
[
"price"
])
||
!
isset
(
$params
[
"commission"
])
||
!
isset
(
$params
[
"commission_arr"
]))
{
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
/* $params = array(
"submit_agent_id" => 1,//申请经纪人id
"submit_agent_name" => 1,//申请经纪人id
"report_id" => 1,//报备id
"order_id" => 1, //关联order表id
"order_no" => "123123123", //订单no
...
...
@@ -192,7 +193,7 @@ class OrderLog extends Basic
$params
[
"commission_arr"
]
=
json_decode
(
$params
[
"commission_arr"
],
true
);
$is_ok
=
$this
->
service_
->
addBargain
(
$params
[
"submit_agent_id"
],
$params
[
"report_id"
],
$params
[
"order_id"
],
$params
[
"order_no"
],
$is_ok
=
$this
->
service_
->
addBargain
(
$params
[
"submit_agent_id"
],
$params
[
"submit_agent_name"
],
$params
[
"report_id"
],
$params
[
"order_id"
],
$params
[
"order_no"
],
$params
[
"trade_type"
],
$params
[
"price"
],
$params
[
"commission"
],
$params
[
"commission_arr"
]);
if
(
$is_ok
>
0
)
{
...
...
application/api_broker/service/OrderLogService.php
View file @
d5f2d6ba
...
...
@@ -116,6 +116,7 @@ class OrderLogService
/**
* 批量插入成交报告
* @param $submit_agent_id
* @param $submit_agent_name
* @param $report_id
* @param $order_id
* @param $order_no
...
...
@@ -125,7 +126,7 @@ class OrderLogService
* @param $commission_arr
* @return int
*/
public
function
addBargain
(
$submit_agent_id
,
$report_id
,
$order_id
,
$order_no
,
$trade_type
,
$price
,
$commission
,
$commission_arr
)
public
function
addBargain
(
$submit_agent_id
,
$submit_agent_name
,
$report_id
,
$order_id
,
$order_no
,
$trade_type
,
$price
,
$commission
,
$commission_arr
)
{
$bargain_arr
=
[];
$father_id
=
0
;
...
...
@@ -133,11 +134,11 @@ class OrderLogService
if
(
isset
(
$commission_val
[
"role"
])
&&
isset
(
$commission_val
[
"agent_id"
])
&&
isset
(
$commission_val
[
"scale"
])
&&
isset
(
$commission_val
[
"scale_fee"
]))
{
if
(
$father_id
==
0
)
{
$params
=
$this
->
bargainBin
(
$father_id
,
$commission_val
,
$submit_agent_id
,
$report_id
,
$order_id
,
$params
=
$this
->
bargainBin
(
$father_id
,
$commission_val
,
$submit_agent_id
,
$submit_agent_name
,
$report_id
,
$order_id
,
$order_no
,
$trade_type
,
$price
,
$commission
);
$father_id
=
$this
->
bargainModel
->
insertBargain
(
$params
);
}
else
{
array_push
(
$bargain_arr
,
$this
->
bargainBin
(
$father_id
,
$commission_val
,
$submit_agent_id
,
$report_id
,
array_push
(
$bargain_arr
,
$this
->
bargainBin
(
$father_id
,
$commission_val
,
$submit_agent_id
,
$submit_agent_name
,
$report_id
,
$order_id
,
$order_no
,
$trade_type
,
$price
,
$commission
));
}
...
...
@@ -150,13 +151,14 @@ class OrderLogService
return
$father_id
;
}
private
function
bargainBin
(
$father_id
,
$commission_val
,
$submit_agent_id
,
$report_id
,
$order_id
,
$order_no
,
$trade_type
,
$price
,
$commission
)
private
function
bargainBin
(
$father_id
,
$commission_val
,
$submit_agent_id
,
$submit_agent_name
,
$report_id
,
$order_id
,
$order_no
,
$trade_type
,
$price
,
$commission
)
{
$arr
[
"report_id"
]
=
$report_id
;
$arr
[
"father_id"
]
=
$father_id
;
$arr
[
"order_no"
]
=
$order_no
;
$arr
[
"order_id"
]
=
$order_id
;
$arr
[
"submit_agent_id"
]
=
$submit_agent_id
;
$arr
[
"submit_agent_name"
]
=
$submit_agent_name
;
$arr
[
"trade_type"
]
=
$trade_type
;
$arr
[
"price"
]
=
$price
;
$arr
[
"commission"
]
=
$commission
;
...
...
@@ -276,7 +278,7 @@ class OrderLogService
}
//成交报告
$field_bargain
=
"id,report_id,order_id,trade_type,submit_agent_id,price,commission,role,agent_id,scale,
$field_bargain
=
"id,report_id,order_id,trade_type,submit_agent_id,
submit_agent_name,
price,commission,role,agent_id,scale,
scale_fee,create_time"
;
$bargainData
=
$oBargainModel
->
selectBargainByOrderNo
(
$field_bargain
,
[
"order_id"
=>
$order_id
]);
if
(
count
(
$bargainData
)
>
0
)
{
...
...
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