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
020edd79
Commit
020edd79
authored
Apr 08, 2019
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
撤销成交报告业绩统计
parent
b619f3dc
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
9 deletions
+7
-9
Finance.php
application/index/controller/Finance.php
+7
-9
No files found.
application/index/controller/Finance.php
View file @
020edd79
...
...
@@ -2649,20 +2649,18 @@ class Finance extends Basic
return
$this
->
response
(
101
,
'收款存在调整,不能撤销!'
);
}
$check
=
$this
->
updatePerformanceAll
(
$this
->
params
[
'bargain_id'
]);
if
(
$check
[
'status'
]
==
'fail'
)
{
return
$this
->
response
(
101
,
'更新个人业绩失败,请重试!'
);
}
$params
[
'content'
]
=
trim
(
$this
->
params
[
'content'
]);
//撤销原因
$m_financial
=
new
OFinancialAudit
();
$result
=
$m_financial
->
backOutUpdate
(
$this
->
params
[
'bargain_id'
],
$params
);
if
(
$result
)
{
$check
=
$this
->
updatePerformanceAll
(
$this
->
params
[
'bargain_id'
]);
if
(
$check
[
'status'
]
==
'fail'
)
{
return
$this
->
response
(
101
,
'更新个人业绩失败,请重试!'
);
}
$code
=
200
;
$this
->
editRecordLog
(
$this
->
params
[
'bargain_id'
],
'[撤销成交报告]'
,
3
);
//日志记录
$this
->
updatePerformanceAll
(
$this
->
params
[
'bargain_id'
],
1
);
$bargain_data
=
$this
->
m_bargain
->
getBargainDetail
(
'order_id,order_no,agent_id'
,
[
'id'
=>
$this
->
params
[
'bargain_id'
]
]);
$financial_data
[
'bargain_id'
]
=
$this
->
params
[
'bargain_id'
];
$financial_data
[
'audit_name'
]
=
$this
->
userName
;
...
...
@@ -2802,7 +2800,7 @@ class Finance extends Basic
$where_bargain
[
'agent_id'
]
=
$agent_id
;
$where_bargain
[
'create_time'
]
=
[
'BETWEEN'
,
[
$date
.
' 00:00:00'
,
$date
.
' 23:59:59'
]];
//实收
$receivedSum
=
$this
->
m_bargain
->
get
ReceivedGroupTimeNew
(
$where_bargain
);
$receivedSum
=
$this
->
m_bargain
->
get
AddBargainNumGroupTimeNew
(
$where_bargain
,
2
);
//1表示业绩 2表示实收
$received_sum
=
empty
(
$receivedSum
[
0
][
"num"
])
?
0
:
$receivedSum
[
0
][
"num"
];
//业绩
...
...
@@ -2810,7 +2808,7 @@ class Finance extends Basic
$performance_sum
=
empty
(
$performanceSum
[
0
][
"num"
])
?
0
:
$performanceSum
[
0
][
"num"
];
$id
=
$m_agent_total
->
getTotalEndTimeByAgentId
(
'id'
,
[
'total_time'
=>
$date
,
'agent_id'
=>
$where_bargain
[
'agent_id'
]]);
if
(
empty
(
$id
[
0
]))
{
if
(
empty
(
$id
[
0
]
[
'id'
]
))
{
$insert_data
[]
=
[
'store_id'
=>
$store_id
,
'district_id'
=>
$district_id
,
...
...
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