From f72bb66356df719f0c1a0b6c3af19d8c8c9d5885 Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Sat, 10 Oct 2020 10:14:56 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=BC=E5=87=BA=E5=85=AC=E5=BC=8F=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AggregateFinanceStatementController.class.php | 10 ++++++++-- .../AggregateStatementPoolController.class.php | 4 ++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/Application/Admin/Controller/AggregateFinanceStatementController.class.php b/Application/Admin/Controller/AggregateFinanceStatementController.class.php index 0de95aaf0..275a1e453 100644 --- a/Application/Admin/Controller/AggregateFinanceStatementController.class.php +++ b/Application/Admin/Controller/AggregateFinanceStatementController.class.php @@ -670,6 +670,8 @@ class AggregateFinanceStatementController extends ThinkController $objPHPExcel->getActiveSheet()->setCellValue('D2','补点比例'); } $line = 3; + $pay_amount_str = "=SUM(F3:"; + $plat_amount_str = "=SUM(C3:"; foreach ($data['statement_info'] as $key => $value) { $objPHPExcel->getActiveSheet()->insertNewRowBefore($line,1); $objPHPExcel->getActiveSheet()->removeConditionalStyles(); @@ -690,8 +692,12 @@ class AggregateFinanceStatementController extends ThinkController $objPHPExcel->getActiveSheet()->getStyle('F'.$line)->getFont()->setBold(false); $line++; } - $objPHPExcel->getActiveSheet()->setCellValue('C'.($line), $data['pay_money']);//合计-平台总额 - $objPHPExcel->getActiveSheet()->setCellValue('F'.($line), $data['ratio_money']);//合计-结算金额 + + $objPHPExcel->getActiveSheet()->setCellValue('C'.($line), $plat_amount_str."C".($line-1).")");//合计-平台总额 + $objPHPExcel->getActiveSheet()->setCellValue('F'.($line), $pay_amount_str."F".($line-1).")");//合计-结算金额 + +// $objPHPExcel->getActiveSheet()->setCellValue('C'.($line), $data['pay_money']);//合计-平台总额 +// $objPHPExcel->getActiveSheet()->setCellValue('F'.($line), $data['ratio_money']);//合计-结算金额 $objPHPExcel->getActiveSheet()->setCellValue('B'.($line+1), $big_all_sum_money);//大写支付结算金额 //甲方信息 $objPHPExcel->getActiveSheet()->setCellValue('B'.($line+3), $data['first_party_info']['partner']);//甲方 diff --git a/Application/Admin/Controller/AggregateStatementPoolController.class.php b/Application/Admin/Controller/AggregateStatementPoolController.class.php index bc92958b6..ce1ad8a5a 100644 --- a/Application/Admin/Controller/AggregateStatementPoolController.class.php +++ b/Application/Admin/Controller/AggregateStatementPoolController.class.php @@ -261,8 +261,8 @@ class AggregateStatementPoolController extends ThinkController $v['statement_count'] = count($v['statement_info']); } if($is_export){ - $count["platform_amount"] = "=SUM(G2:G".$line.")"; - $count["sum_money"] = "=SUM(L2:L".$line.")"; + $count["platform_amount"] = "=ROUND(SUM(G2:G".$line."),2)"; + $count["sum_money"] = "=ROUND(SUM(L2:L".$line."),2)"; } $this->assign("data",$infolist);