From 6c3aefcf5520c9f452116a9f181b046efd7435f6 Mon Sep 17 00:00:00 2001 From: chenzhi Date: Thu, 25 Mar 2021 11:14:03 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=AD=90=E7=AB=99=E4=B8=8A?= =?UTF-8?q?=E6=B8=B8=E6=AF=94=E4=BE=8B=E6=8C=89=E5=AE=9E=E9=99=85=E7=BB=93?= =?UTF-8?q?=E7=AE=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...SubCompanyStatementSetController.class.php | 20 ++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/Application/Admin/Controller/SubCompanyStatementSetController.class.php b/Application/Admin/Controller/SubCompanyStatementSetController.class.php index af5e1671a..d160f6d34 100644 --- a/Application/Admin/Controller/SubCompanyStatementSetController.class.php +++ b/Application/Admin/Controller/SubCompanyStatementSetController.class.php @@ -24,16 +24,16 @@ class SubCompanyStatementSetController extends Controller { echo "请先设置请求接口aggregate_cp_settlement_api的值".PHP_EOL;die; } $this->cpapihost = $cpapihost['value']; - $this->synGame(); + // $this->synGame(); } //同步游戏表 - protected function synGame() - { - $mainGame = M("Game","tab_")->select(); - SM()->execute("truncate table tab_game"); - M("game","tab_",SUBSITE_DB)->addAll($mainGame); - } + // protected function synGame() + // { + // $mainGame = M("Game","tab_")->select(); + // SM()->execute("truncate table tab_game"); + // M("game","tab_",SUBSITE_DB)->addAll($mainGame); + // } /** * Undocumented function * @@ -258,7 +258,6 @@ class SubCompanyStatementSetController extends Controller { $statement_begin_time = date("Y.m.d",$begintime); $statement_end_time = date("Y.m.d",$endtime); $MainStatementDb = M("CompanyStatement","tab_"); //主站结算单 - // dd($cpList); foreach($cpList as $k=>$v){ // $sub_company_id = ($v['first_company_type'] == 1 ? $v['first_company_id'] : $v['second_company_id']); @@ -277,10 +276,13 @@ class SubCompanyStatementSetController extends Controller { if(isset($v['list'][$igm])){ $add_data['statement_info'][$index]['platform_money'] = $v['list'][$igm]['platform_money']; $add_data['statement_info'][$index]['aggregate_money'] = $v['list'][$igm]['aggregate_money']; - $add_data['statement_info'][$index]['ratio'] = $add_data['statement_info'][$index][$ratio_str]; + $game_pay_amount = $v['list'][$igm]['platform_money']-0+$v['list'][$igm]['aggregate_money']; + $ratio = getGameCpRadio($item['relation_game_id'], $game_pay_amount, true) - 0; + $add_data['statement_info'][$index]['ratio'] = $ratio; }else{ $add_data['statement_info'][$index]['platform_money'] = 0; $add_data['statement_info'][$index]['aggregate_money'] = 0; + $add_data['statement_info'][$index]['ratio'] = 0; } } unset($add_data['id'],$add_data['remark'],$add_data['confirm_status'],$add_data['confirm_log']);