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
6dc7e6fc
Commit
6dc7e6fc
authored
Nov 28, 2018
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
收佣日期统计
parent
ada6135b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
1 deletion
+25
-1
Finance.php
application/index/controller/Finance.php
+14
-1
ORealIncome.php
application/model/ORealIncome.php
+11
-0
No files found.
application/index/controller/Finance.php
View file @
6dc7e6fc
...
...
@@ -1008,7 +1008,7 @@ class Finance extends Basic
$check
=
new
VipService
();
$data
=
$this
->
params
[
"commission_date"
];
$add_arr
=
$update_arr
=
$log_data
=
[];
$add_arr
=
$update_arr
=
$log_data
=
$real_income_id
=
[];
$i
=
$j
=
0
;
foreach
(
$data
as
$item
)
{
if
(
!
isset
(
$item
[
'practical_fee'
])
||
!
isset
(
$item
[
'cash'
])
||
!
isset
(
$item
[
'service_charge'
])
||
...
...
@@ -1087,6 +1087,10 @@ class Finance extends Basic
'create_time'
=>
$bargain_data
[
'create_time'
],
];
}
if
(
!
empty
(
$item
[
'real_income_id'
]))
{
$real_income_id
[]
=
$item
[
'real_income_id'
];
}
}
if
(
$j
>
0
)
{
...
...
@@ -1113,6 +1117,15 @@ class Finance extends Basic
$update_data
[
'agent_id'
]
=
$v
[
'agent_id'
];
$this
->
m_bargain
->
updateBargainById
(
$v
[
'bargain_id'
],
$update_data
);
$this
->
updatePerformanceData
(
$v
[
'agent_id'
],
$v
[
'create_time'
],
$v
[
'store_id'
],
$v
[
'district_id'
]);
//todo 收佣日期统计
if
(
!
empty
(
$real_income_id
))
{
$m_real
=
new
ORealIncome
();
$income_time
=
$m_real
->
getBargainTaxesColumn
(
'income_time'
,
[
'id'
=>
[
'in'
,
array_unique
(
$real_income_id
)]]);
foreach
(
$income_time
as
$v2
)
{
$this
->
updatePerformanceData
(
$v
[
'agent_id'
],
$v2
,
$v
[
'store_id'
],
$v
[
'district_id'
]);
}
}
}
}
// $data = $m_partial->addCommission($this->params, $this->userId);
...
...
application/model/ORealIncome.php
View file @
6dc7e6fc
...
...
@@ -37,6 +37,17 @@ class ORealIncome extends BaseModel
->
select
();
}
/**
* @param int $field
* @param array $where
* @return array
*/
public
function
getBargainTaxesColumn
(
$field
,
array
$where
)
{
return
$this
->
field
(
$field
)
->
where
(
$where
)
->
column
(
$field
);
}
/**
* @param string $field
* @param $where
...
...
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