From 8fb73e6fede24f2f71205a0edd0ccfead3922eae Mon Sep 17 00:00:00 2001 From: zhengyongxing Date: Tue, 20 Apr 2021 10:28:02 +0800 Subject: [PATCH] =?UTF-8?q?4.22=E5=8F=B7=E5=8A=9F=E8=83=BD=E6=8F=90?= =?UTF-8?q?=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controller/CompanyStatementSetController.class.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Application/Admin/Controller/CompanyStatementSetController.class.php b/Application/Admin/Controller/CompanyStatementSetController.class.php index 02e956cf5..8b5de7dac 100644 --- a/Application/Admin/Controller/CompanyStatementSetController.class.php +++ b/Application/Admin/Controller/CompanyStatementSetController.class.php @@ -376,13 +376,14 @@ class CompanyStatementSetController extends Controller { if($type < 2){ //非补点奖罚 $rrmap = array( - "confirm_time" => ['between', [$begintime,$endtime]], + "d.confirm_time" => ['between', [$begintime,$endtime]], "company_type"=>1, "company_id"=>$add_data['company_id'], "settlement_type"=>2, "is_verify"=>1, ); $rfres = M("RewardDetail","tab_") + ->alias("d") ->field(" IFNULL(SUM(CASE WHEN type = 1 THEN amount ELSE 0 END),0) as reward_count, IFNULL(SUM(CASE WHEN type = 2 THEN amount ELSE 0 END),0) as fine_count @@ -891,13 +892,14 @@ class CompanyStatementSetController extends Controller { if($type < 2){ //非补点计算奖罚 $rrmap = array( - "confirm_time" => ['between', [$begintime,$endtime]], + "d.confirm_time" => ['between', [$begintime,$endtime]], "company_type"=>2, "company_id"=>$add_data['company_id'], "settlement_type"=>2, "is_verify"=>1, ); $rfres = M("RewardDetail","tab_") + ->alias("d") ->field(" IFNULL(SUM(CASE WHEN type = 1 THEN amount ELSE 0 END),0) as reward_count, IFNULL(SUM(CASE WHEN type = 2 THEN amount ELSE 0 END),0) as fine_count