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
2ffda816
Commit
2ffda816
authored
Jul 31, 2019
by
hujun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
税费承担明细表
parent
2368a994
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
86 additions
and
35 deletions
+86
-35
OfficeFinance.php
application/index/controller/OfficeFinance.php
+85
-35
route.php
application/route.php
+1
-0
No files found.
application/index/controller/OfficeFinance.php
View file @
2ffda816
...
...
@@ -8,44 +8,10 @@
namespace
app\index\controller
;
use
app\api\service\ConvertCouponService
;
use
app\api\service\CouponService
;
use
app\api_broker\service\OrderLogService
;
use
app\api_broker\service\PayLogOpenService
;
use
app\api_broker\service\PayLogService
;
use
app\api_broker\service\RedisCacheService
;
use
app\api_broker\service\VipService
;
use
app\index\extend\Basic
;
use
app\index\untils\ExportExcelUntil
;
use
app\model\AAgents
;
use
app\model\AStore
;
use
app\model\GHouses
;
use
app\model\GHousesToAgents
;
use
app\model\OBargainLogModel
;
use
app\model\OBargainModel
;
use
app\model\ODaily
;
use
app\model\OfficeOImg
;
use
app\model\OfficeOPartialCommission
;
use
app\model\OfficeOPayLogModel
;
use
app\model\OImg
;
use
app\model\OMarchInModel
;
use
app\model\OPayLogAdjustment
;
use
app\model\OPayLogOpen
;
use
app\model\OPayLogOpenLog
;
use
app\model\OrderModel
;
use
app\model\ORealIncome
;
use
app\model\ORefundLogModel
;
use
app\model\OReportModel
;
use
app\model\OTaxes
;
use
app\model\OFinancialAudit
;
use
app\model\OPartialCommission
;
use
app\model\OPayLogModel
;
use
app\model\ORefundModel
;
use
app\model\TAgentTotalModel
;
use
app\model\Users
;
use
app\task\controller\ResultsSummaryNewTask
;
use
think\Exception
;
use
app\model\OfficeOTaxes
;
use
think\Request
;
class
OfficeFinance
extends
Basic
...
...
@@ -142,4 +108,88 @@ class OfficeFinance extends Basic
return
$this
->
response
(
"200"
,
"request success"
,
$data
);
}
/**
* 税费承担明细表
*
* @return \think\Response
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\ModelNotFoundException
* @throws \think\exception\DbException
*/
public
function
getTallAgeList
()
{
if
(
!
$this
->
request
->
isAjax
()
&&
(
$this
->
params
[
'excel'
]
!=
1
))
{
return
view
(
'tax'
);
}
$data
[
'code'
]
=
200
;
$data
[
'msg'
]
=
""
;
$data
[
'data'
]
=
[];
$pageNo
=
empty
(
$this
->
params
[
'pageNo'
])
?
1
:
$this
->
params
[
'pageNo'
];
$pageSize
=
empty
(
$this
->
params
[
'pageSize'
])
?
15
:
$this
->
params
[
'pageSize'
];
$where
[
'a.is_del'
]
=
0
;
$where
[
'a.father_id'
]
=
[
'neq'
,
0
];
if
(
!
empty
(
$this
->
params
[
'create_time'
])
&&
empty
(
$this
->
params
[
'end_time'
]))
{
$where
[
'a.operation_date'
]
=
[
'> time'
,
$this
->
params
[
'create_time'
]
.
' 00:00:00'
];
}
if
(
!
empty
(
$this
->
params
[
'end_time'
])
&&
empty
(
$this
->
params
[
'create_time'
]))
{
$where
[
'a.operation_date'
]
=
[
'< time'
,
$this
->
params
[
'end_time'
]
.
' 23:59:59'
];
}
if
(
!
empty
(
$this
->
params
[
'end_time'
])
&&
!
empty
(
$this
->
params
[
'create_time'
]))
{
$where
[
'a.operation_date'
]
=
[
'between time'
,
[
$this
->
params
[
'create_time'
]
.
' 00:00:00'
,
$this
->
params
[
'end_time'
]
.
' 23:59:59'
]
];
}
if
(
!
empty
(
$this
->
params
[
'internal_address'
]))
{
$where
[
'd.internal_address'
]
=
[
'like'
,
'%'
.
$this
->
params
[
'internal_address'
]
.
'%'
];
}
if
(
!
empty
(
$this
->
params
[
'phone'
]))
{
$where
[
'e.phone'
]
=
[
'like'
,
'%'
.
$this
->
params
[
'phone'
]
.
'%'
];
}
if
(
!
empty
(
$this
->
params
[
'name'
]))
{
$where
[
'e.name'
]
=
[
'like'
,
'%'
.
$this
->
params
[
'name'
]
.
'%'
];
}
if
(
!
empty
(
$this
->
params
[
'house_number'
]))
{
$where
[
'b.house_number'
]
=
[
'like'
,
'%'
.
$this
->
params
[
'house_number'
]
.
'%'
];
}
if
(
!
empty
(
$this
->
params
[
'bargain_id'
]))
{
$where
[
'b.id'
]
=
$this
->
params
[
'bargain_id'
];
}
$m_fee
=
new
OfficeOTaxes
();
$fields
=
'a.id,a.operation_date,e.name,e.phone,a.fee,b.house_number,d.internal_address,a.agent_id,b.father_id,b.id as bargain_id,b.order_id'
;
if
(
$this
->
params
[
'excel'
]
!=
1
)
{
$data
[
'data'
][
'list'
]
=
$m_fee
->
getTaxesList
(
$pageNo
,
$pageSize
,
'a.id desc'
,
$fields
,
$where
);
$data
[
'data'
][
'total'
]
=
$m_fee
->
getTaxesListTotal
(
$where
);
$data
[
'data'
][
'total_fee'
]
=
$m_fee
->
getTaxesListTotalFee
(
$where
);
return
$this
->
response
(
$data
[
'code'
],
$data
[
'msg'
],
$data
[
'data'
]);
}
else
{
$data
[
'data'
]
=
$m_fee
->
getTaxesList
(
$pageNo
,
50000
,
'a.id desc'
,
$fields
,
$where
);
if
(
count
(
$data
[
'data'
])
>
0
)
{
$excel_data
=
[];
foreach
(
$data
[
'data'
]
as
$k
=>
$v
)
{
$excel_data
[
$k
][
'bargain_id'
]
=
$v
[
'bargain_id'
];
$excel_data
[
$k
][
'operation_date'
]
=
$v
[
'operation_date'
];
$excel_data
[
$k
][
'district_store'
]
=
$v
[
'district_store'
];
$excel_data
[
$k
][
'name'
]
=
$v
[
'name'
];
$excel_data
[
$k
][
'internal_address'
]
=
$v
[
'internal_address'
];
$excel_data
[
$k
][
'house_number'
]
=
$v
[
'house_number'
];
$excel_data
[
$k
][
'fee'
]
=
$v
[
'fee'
];
}
$export
=
new
ExportExcelUntil
();
$title
=
[
'成交报告ID'
,
'开票日期'
,
'所属部门/门店'
,
'业务员'
,
'商铺地址'
,
'商铺号'
,
'税费(元)'
];
$export
->
exportTable
(
'税费明细'
,
$excel_data
,
7
,
'税费明细'
,
$title
);
}
else
{
return
$this
->
response
(
101
,
'数据为空'
);
}
}
}
}
application/route.php
View file @
2ffda816
...
...
@@ -1205,6 +1205,7 @@ Route::group('office_index', [
'checkOver'
=>
[
'index/OfficeBargain/checkOver'
,
[
'method'
=>
'POST'
]],
//财务结单
'toReportListOne'
=>
[
'index/OfficeBargain/toReportListOne'
,
[
'method'
=>
'POST'
]],
//回到一级审核
'partialCommissionList'
=>
[
'index/OfficeFinance/partialCommissionList'
,
[
'method'
=>
'get'
]],
//分佣提成明细表
'getTallAgeList'
=>
[
'index/OfficeFinance/getTallAgeList'
,
[
'method'
=>
'GET'
]],
//税费承担明细表
'performanceInfo'
=>
[
'index/OfficePerformanceInfo/performanceInfo'
,
[
'method'
=>
'GET|POST'
]],
//业绩明细办公楼
'selectDistrictPerformance'
=>
[
'index/OfficePerformance/selectDistrictPerformance'
,
[
'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