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
3210b200
Commit
3210b200
authored
May 03, 2018
by
zw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
返回提交id
parent
7b57f567
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
62 additions
and
5 deletions
+62
-5
OrderLog.php
application/api_broker/controller/OrderLog.php
+22
-1
OrderLogService.php
application/api_broker/service/OrderLogService.php
+15
-4
OPayLogModel.php
application/model/OPayLogModel.php
+24
-0
route.php
application/route.php
+1
-0
No files found.
application/api_broker/controller/OrderLog.php
View file @
3210b200
...
...
@@ -112,11 +112,32 @@ class OrderLog extends Basic
$params
[
"collecting_bill"
],
$params
[
"house_number"
],
$params
[
"industry_type"
],
$remark
,
$transfer_img
);
if
(
$is_ok
>
0
)
{
return
$this
->
response
(
"200"
,
"request success"
,
[]);
return
$this
->
response
(
"200"
,
"request success"
,
[
"bill_id"
=>
$is_ok
]);
}
return
$this
->
response
(
"101"
,
"request faild"
);
}
/**
* 获取上次提交付款的门牌号业态等
* @return \think\Response
*/
public
function
getBeforeBillInfo
(){
$params
=
$this
->
params
;
/* $params = array(
"order_id" => 15523, //关联order表id
);*/
if
(
!
isset
(
$params
[
"order_id"
]))
{
return
$this
->
response
(
"101"
,
"订单编号不能为空"
);
}
$billInfo
=
$this
->
service_
->
getBillInfo
(
$params
[
"order_id"
]);
if
(
count
(
$billInfo
)
>
0
){
return
$this
->
response
(
"200"
,
"request success"
,
$billInfo
[
0
]);
}
else
{
return
$this
->
response
(
"200"
,
"request null"
);
}
}
/**
* 新增退款申请
* @return \think\Response
...
...
application/api_broker/service/OrderLogService.php
View file @
3210b200
...
...
@@ -70,12 +70,13 @@ class OrderLogService
}
}
}
//todo if bill_arr not null, save database table
if
(
!
empty
(
$bill_arr
))
{
$id
=
$this
->
payLogModel
->
addPayLog
(
$bill_arr
);
if
(
$father_id
>
0
){
$pushMarchIn
=
new
PushMessageService
(
$params
[
"report_id"
],
2
);
$pushMarchIn
->
pushMarchInMessage
(
$params
[
"report_id"
],
2
);
//推送
return
$id
;
}
//todo if bill_arr not null, save database table
if
(
!
empty
(
$bill_arr
))
{
return
$this
->
payLogModel
->
addPayLog
(
$bill_arr
);
}
return
$father_id
;
}
...
...
@@ -886,4 +887,13 @@ class OrderLogService
return
$list
;
}
/**
* @param $order_id
* @return false|\PDOStatement|string|\think\Collection
*/
public
function
getBillInfo
(
$order_id
){
$filed
=
"house_number,industry_type"
;
return
$this
->
payLogModel
->
getBeforeBillInfo
(
$filed
,[
"order_id"
=>
$order_id
]);
}
}
\ No newline at end of file
application/model/OPayLogModel.php
View file @
3210b200
...
...
@@ -77,6 +77,30 @@ class OPayLogModel extends Model
->
where
(
$where_
)
->
select
();
}
/**
* 获取上次提交记录
* @param $filed
* @param $params
* @return false|\PDOStatement|string|\think\Collection
*/
public
function
getBeforeBillInfo
(
$filed
,
$params
)
{
$where_
=
[];
if
(
isset
(
$params
[
"order_id"
]))
{
$where_
[
"order_id"
]
=
$params
[
"order_id"
];
}
$where_
[
"father_id"
]
=
0
;
return
$this
->
db_
->
field
(
$filed
)
->
where
(
$where_
)
->
limit
(
1
)
->
select
();
}
public
function
getPayLogByOrderId
(
$field
,
$params
){
$where_
=
[];
if
(
isset
(
$params
[
"order_id"
])){
...
...
application/route.php
View file @
3210b200
...
...
@@ -334,6 +334,7 @@ Route::group('broker', [
'addFollowUp'
=>
[
'api_broker/Report/addFollowUp'
,
[
'method'
=>
'get|post'
]
],
//新增跟进
'getFollowUpList'
=>
[
'api_broker/Report/getFollowUpList'
,
[
'method'
=>
'get|post'
]
],
'marchIn'
=>
[
'api_broker/OrderLog/marchIn'
,
[
'method'
=>
'get|post'
]
],
'getBeforeBillInfo'
=>
[
'api_broker/OrderLog/getBeforeBillInfo'
,
[
'method'
=>
'get|post'
]
],
'collectingBill'
=>
[
'api_broker/OrderLog/collectingBill'
,
[
'method'
=>
'get|post'
]
],
'refund'
=>
[
'api_broker/OrderLog/refund'
,
[
'method'
=>
'get|post'
]
],
'bargain'
=>
[
'api_broker/OrderLog/bargain'
,
[
'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