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
7d9016ca
Commit
7d9016ca
authored
Sep 21, 2018
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
145d9d52
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
4 deletions
+27
-4
Finance.php
application/index/controller/Finance.php
+27
-4
No files found.
application/index/controller/Finance.php
View file @
7d9016ca
...
...
@@ -781,15 +781,38 @@ class Finance extends Basic
$where
[
'a.confirm_status'
]
=
1
;
$where
[
'a.is_del'
]
=
0
;
if
(
!
empty
(
$this
->
params
[
'create_time'
])
&&
empty
(
$this
->
params
[
'end_time'
]))
{
$
where
[
'a.confirm_dat
e'
]
=
[
'>= time'
,
$this
->
params
[
'create_time'
]
.
' 00:00:00'
];
$
income_where
[
'income_tim
e'
]
=
[
'>= time'
,
$this
->
params
[
'create_time'
]
.
' 00:00:00'
];
}
if
(
!
empty
(
$this
->
params
[
'end_time'
])
&&
empty
(
$this
->
params
[
'create_time'
]))
{
$
where
[
'a.confirm_date'
]
=
[
'<= time'
,
$this
->
params
[
'create
_time'
]
.
' 23:59:59'
];
$
income_where
[
'income_time'
]
=
[
'<= time'
,
$this
->
params
[
'end
_time'
]
.
' 23:59:59'
];
}
if
(
!
empty
(
$this
->
params
[
'end_time'
])
&&
!
empty
(
$this
->
params
[
'create_time'
]))
{
$where
[
'a.confirm_date'
]
=
[
'between time'
,
[
$this
->
params
[
'create_time'
]
.
' 00:00:00'
,
$this
->
params
[
'create_time'
]
.
' 23:59:59'
]
];
$income_where
[
'income_time'
]
=
[
'between time'
,
[
$this
->
params
[
'create_time'
]
.
' 00:00:00'
,
$this
->
params
[
'end_time'
]
.
' 23:59:59'
]
];
}
if
(
!
empty
(
$income_where
))
{
$m_real
=
new
ORealIncome
();
$bargain_arr
=
$m_real
->
getRealIncomeBargain
(
'bargain_id'
,
$income_where
);
if
(
$bargain_arr
[
'status'
]
==
'successful'
)
{
if
(
empty
(
$bargain_arr
[
'data'
]))
{
return
$this
->
response
(
200
,
''
);
}
foreach
(
$bargain_arr
[
'data'
]
as
$v
)
{
$bargain_id
[]
=
$v
[
'bargain_id'
];
}
if
(
!
empty
(
$bargain_id
))
{
$bargain_id_string
=
implode
(
','
,
$bargain_id
);
$where
[]
=
[
'EXP'
,
'b.id in ('
.
$bargain_id_string
.
') or b.father_id in ('
.
$bargain_id_string
.
')'
];
}
}
else
{
return
$this
->
response
(
101
,
'内部错误:'
.
$bargain_arr
[
'msg'
]);
}
}
if
(
!
empty
(
$this
->
params
[
'internal_address'
]))
{
...
...
@@ -1448,7 +1471,7 @@ class Finance extends Basic
$pageSize
=
25000
;
$result_data
=
$m_bargain
->
getCommissionTotalListV2
(
$pageNo
,
$pageSize
,
'a.agent_id desc'
,
$fields
,
$where
,
$operation_start_data
,
$operation_end_data
);
if
(
$result_data
[
'status'
]
==
'succesful'
)
{
if
(
$result_data
[
'status'
]
==
'succes
s
ful'
)
{
$data
=
$result_data
[
'data'
];
foreach
(
$data
as
$k
=>
$v
)
{
$excel_data
[
$k
][
'income_date'
]
=
$income_date
;
//收佣日期
...
...
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