diff --git a/Application/Admin/Controller/FinanceController.class.php b/Application/Admin/Controller/FinanceController.class.php index 2a2571ccb..aed71247f 100644 --- a/Application/Admin/Controller/FinanceController.class.php +++ b/Application/Admin/Controller/FinanceController.class.php @@ -815,7 +815,7 @@ class FinanceController extends ThinkController } else { $row = 10; } - $map['pay_status'] = 1; + $map['pay_game_status'] = 1; if (!empty(I("game_id"))) { $map['game_id'] = I("game_id"); } @@ -829,12 +829,14 @@ class FinanceController extends ThinkController $field = "pay_order_number,FROM_UNIXTIME(pay_time) as pay_time,user_account,user_nickname,game_name,promote_account,spend_ip,server_name,game_player_name,pay_amount,cost,pay_way"; $group = ""; $order = "pay_time DESC"; + $data = D('spend')->getSpendData($map,$field,$group,$order,$page,$row); foreach($data as $key => $value) { $data[$key]['pay_way'] = getPayType($value['pay_way']); } $totalData = D('spend')->totalGameStatistics($map, false); + $sumCash = $totalData['cash_count'] ?? 0; $sumBalance = $totalData['balance_coin_count'] ?? 0; $sumInside = $totalData['inside_cash_count'] ?? 0; diff --git a/Application/Admin/Model/SpendModel.class.php b/Application/Admin/Model/SpendModel.class.php index 31a4385f2..f7177406b 100644 --- a/Application/Admin/Model/SpendModel.class.php +++ b/Application/Admin/Model/SpendModel.class.php @@ -873,6 +873,7 @@ SUM(CASE WHEN pay_way = -1 THEN pay_amount ELSE 0 END) as inside_cash_count"); $data = $query->where(['s.pay_status' => 1, 'pay_game_status' => 1]) ->where($map) ->find(); +// dd($query->_sql()); return $data; } diff --git a/Application/Admin/View/Finance/gameStatistics.html b/Application/Admin/View/Finance/gameStatistics.html index c657ecdc9..ea095add9 100644 --- a/Application/Admin/View/Finance/gameStatistics.html +++ b/Application/Admin/View/Finance/gameStatistics.html @@ -72,7 +72,7 @@
说明:仅统计通知成功