diff --git a/Application/Admin/Controller/CompanyStatementController.class.php b/Application/Admin/Controller/CompanyStatementController.class.php index 0743c12af..4bfb3d8b8 100644 --- a/Application/Admin/Controller/CompanyStatementController.class.php +++ b/Application/Admin/Controller/CompanyStatementController.class.php @@ -498,7 +498,12 @@ class CompanyStatementController extends ThinkController $v['verify_status'] = 5; $v['verify_log'] = json_encode(["create_user"=>$this->admininfo["username"],"create_time"=>date("Y-m-d H:i:s"),"verify_user"=>"system","verify_time"=>date("Y-m-d H:i:s"),"payment_user"=>"system","payment_time"=>date("Y-m-d H:i:s")]); } - + //判断周月结 + if(($v["statement_end_time"]-$v['statement_begin_time']) > 7*24*3600){ + $v["withdraw_type"] = 1; + }else{ + $v["withdraw_type"] = 0; + } $pool_id = $Pool->add($v); if($pool_id == false){ $this->ajaxReturn(array('status' => 0,"info"=>"汇总失败")); diff --git a/Application/Admin/Controller/CompanyStatementPoolController.class.php b/Application/Admin/Controller/CompanyStatementPoolController.class.php index 8882d4205..88a25469b 100644 --- a/Application/Admin/Controller/CompanyStatementPoolController.class.php +++ b/Application/Admin/Controller/CompanyStatementPoolController.class.php @@ -16,7 +16,11 @@ class CompanyStatementPoolController extends ThinkController "1"=>"是", "2"=>"否" ]; - + public $WithdrawType = [ + "0"=>"周结", + "1"=>"月结", + "2"=>"下游个人补点" + ]; public $VerifyStatus=[ "-2"=>"拒绝打款", "-1"=>"审批拒绝", @@ -94,6 +98,9 @@ class CompanyStatementPoolController extends ThinkController if(isset($_REQUEST['is_payment'])){ $map['is_payment'] = $_REQUEST['is_payment']; } + if(isset($_REQUEST['withdraw_type'])){ + $map['withdraw_type'] = $_REQUEST['withdraw_type']; + } // $this->checkListOrCountAuthRestMap($map);//导出权限 @@ -116,6 +123,7 @@ class CompanyStatementPoolController extends ThinkController $v["valid"] = "{$v['statement_begin_time']} ~ {$v['statement_end_time']}"; $v['ext_file_type'] = empty($v['ext_file']) ? "无" : "有"; + $v['withdraw_type'] = $this->WithdrawType[$v['withdraw_type']];; $v['verify_log'] = json_decode($v['verify_log'], true); if (isset($params['export'])) { @@ -177,6 +185,7 @@ class CompanyStatementPoolController extends ThinkController $this->assign('CompanyType',$this->CompanyType); $this->assign('IsPayment',$this->IsPayment); $this->assign('VerifyStatus',$this->VerifyStatus); + $this->assign('WithdrawType',$this->WithdrawType); $this->display(); } @@ -232,7 +241,11 @@ class CompanyStatementPoolController extends ThinkController if($is_export){ //J3*(K3+L3)+M3-N3 - $va['sum_money'] = "=J{$line}*(K{$line}+L{$line})+M{$line}-N{$line}"; + if($va['statement_type'] > 0){ //罚款服务器费用 + $va['sum_money'] = "=J{$line}"; + }else{ + $va['sum_money'] = "=J{$line}*(K{$line}+L{$line})+M{$line}-N{$line}"; + } $count['sum_money_exp'] .= "O{$line}+"; $count['platform_amount_exp'] .= "J{$line}+"; @@ -284,7 +297,7 @@ class CompanyStatementPoolController extends ThinkController if($is_export){ $v['statement_money_exp'] .= "H{$line}+"; - + $va['d_statement_money'] = "=D{$line}*(1-G{$line})*(E{$line}+F{$line})"; $count['platform_amount_exp'] .= "D{$line}+"; diff --git a/Application/Admin/View/CompanyStatementPool/lists.html b/Application/Admin/View/CompanyStatementPool/lists.html index d83953056..d40073fee 100644 --- a/Application/Admin/View/CompanyStatementPool/lists.html +++ b/Application/Admin/View/CompanyStatementPool/lists.html @@ -102,6 +102,15 @@ +