|
@@ -597,8 +597,8 @@ class GlobalUser extends BaseApiLogic
|
|
|
// 签到总奖励
|
|
// 签到总奖励
|
|
|
$totalSignIn = $AccountsInfoModel->accountSignIn();
|
|
$totalSignIn = $AccountsInfoModel->accountSignIn();
|
|
|
// 周卡购买报表
|
|
// 周卡购买报表
|
|
|
- $weeklyCard = $GlobalLogic->WeeklyCard();
|
|
|
|
|
- return compact('paySum', 'payUserCount', 'withdraw', 'withDrawRecovery', 'dormancyUser', 'lsUser', 'register', 'totalSignIn', 'weeklyCard');
|
|
|
|
|
|
|
+// $weeklyCard = $GlobalLogic->WeeklyCard();
|
|
|
|
|
+ return compact('paySum', 'payUserCount', 'withdraw', 'withDrawRecovery', 'dormancyUser', 'lsUser', 'register','totalSignIn');
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// 全局报表 - 游戏相关
|
|
// 全局报表 - 游戏相关
|
|
@@ -613,6 +613,7 @@ class GlobalUser extends BaseApiLogic
|
|
|
foreach ($gameInfo as &$value) {
|
|
foreach ($gameInfo as &$value) {
|
|
|
$value = number_float($value / NumConfig::NUM_VALUE);
|
|
$value = number_float($value / NumConfig::NUM_VALUE);
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
unset($value);
|
|
unset($value);
|
|
|
// 房间库存
|
|
// 房间库存
|
|
|
$roomStock = GameRoomInfo::RoomStock(config('games.openKGame'));
|
|
$roomStock = GameRoomInfo::RoomStock(config('games.openKGame'));
|
|
@@ -636,6 +637,10 @@ class GlobalUser extends BaseApiLogic
|
|
|
$gameRoomInfo->win_lose=$gameRoomInfo2->win_lose;
|
|
$gameRoomInfo->win_lose=$gameRoomInfo2->win_lose;
|
|
|
$gameRoomInfo->pay_win_lose=$gameRoomInfo2->pay_win_lose;
|
|
$gameRoomInfo->pay_win_lose=$gameRoomInfo2->pay_win_lose;
|
|
|
|
|
|
|
|
|
|
+ $gameRoomInfo->free_flowing_water = $gameRoomInfo->flowing_water_new-$gameRoomInfo->pay_flowing_water_new;
|
|
|
|
|
+
|
|
|
|
|
+ $gameRoomInfo->free_win_lose = $gameRoomInfo->win_lose-$gameRoomInfo->pay_win_lose;
|
|
|
|
|
+
|
|
|
// 游戏人数
|
|
// 游戏人数
|
|
|
$totalGameCount = DB::table(TableName::QPRecordDB() . 'RecordUserGameDayCount')
|
|
$totalGameCount = DB::table(TableName::QPRecordDB() . 'RecordUserGameDayCount')
|
|
|
->whereBetween('DateID', [$StartDataID, $EndDataID])
|
|
->whereBetween('DateID', [$StartDataID, $EndDataID])
|
|
@@ -653,7 +658,7 @@ class GlobalUser extends BaseApiLogic
|
|
|
unset($value);
|
|
unset($value);
|
|
|
if (!empty($gameRoomInfo)) {
|
|
if (!empty($gameRoomInfo)) {
|
|
|
// 平台输赢 = 输赢 + 税收
|
|
// 平台输赢 = 输赢 + 税收
|
|
|
- $gameRoomInfo->win_lose = $gameRoomInfo->win_lose + $gameRoomInfo->Revenue;
|
|
|
|
|
|
|
+// $gameRoomInfo->win_lose = $gameRoomInfo->win_lose;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// 游戏房间数据 -- 列表
|
|
// 游戏房间数据 -- 列表
|
|
@@ -690,22 +695,27 @@ class GlobalUser extends BaseApiLogic
|
|
|
$value->ServerName = '';
|
|
$value->ServerName = '';
|
|
|
$value->flowing_water = is_null($value->flowing_water) ? 0 : number_float($value->flowing_water / NumConfig::NUM_VALUE);
|
|
$value->flowing_water = is_null($value->flowing_water) ? 0 : number_float($value->flowing_water / NumConfig::NUM_VALUE);
|
|
|
$value->flowing_water_new = is_null($value->flowing_water_new) ? 0 : number_float($value->flowing_water_new / NumConfig::NUM_VALUE);
|
|
$value->flowing_water_new = is_null($value->flowing_water_new) ? 0 : number_float($value->flowing_water_new / NumConfig::NUM_VALUE);
|
|
|
- $value->Revenue = is_null($value->Revenue) ? 0 : number_float($value->Revenue / NumConfig::NUM_VALUE);
|
|
|
|
|
|
|
+
|
|
|
|
|
+// $value->Revenue = is_null($value->Revenue) ? 0 : number_float($value->Revenue / NumConfig::NUM_VALUE);
|
|
|
|
|
|
|
|
$value->pay_flowing_water_new = is_null($value->pay_flowing_water_new) ? 0 : number_float($value->pay_flowing_water_new / NumConfig::NUM_VALUE);
|
|
$value->pay_flowing_water_new = is_null($value->pay_flowing_water_new) ? 0 : number_float($value->pay_flowing_water_new / NumConfig::NUM_VALUE);
|
|
|
- $value->pay_Revenue = is_null($value->pay_Revenue) ? 0 : number_float($value->pay_Revenue / NumConfig::NUM_VALUE);
|
|
|
|
|
|
|
+// $value->pay_Revenue = is_null($value->pay_Revenue) ? 0 : number_float($value->pay_Revenue / NumConfig::NUM_VALUE);
|
|
|
|
|
+
|
|
|
|
|
+ $value->free_flowing_water = $value->flowing_water_new-$value->pay_flowing_water_new;
|
|
|
|
|
|
|
|
//玩家不扣税的游戏不累计到统计里
|
|
//玩家不扣税的游戏不累计到统计里
|
|
|
- if(!in_array($value->GameID,$revenueGames)){
|
|
|
|
|
- $gameRoomInfo->win_lose = $gameRoomInfo->win_lose-$value->Revenue;
|
|
|
|
|
- $gameRoomInfo->pay_win_lose = $gameRoomInfo->pay_win_lose-$value->pay_Revenue;
|
|
|
|
|
- $gameRoomInfo->Revenue = $gameRoomInfo->Revenue-$value->Revenue; //真是税收收入
|
|
|
|
|
- $gameRoomInfo->pay_Revenue = $gameRoomInfo->pay_Revenue-$value->pay_Revenue; //真是税收收入
|
|
|
|
|
- }
|
|
|
|
|
|
|
+// if(!in_array($value->GameID,$revenueGames)){
|
|
|
|
|
+// $gameRoomInfo->win_lose = $gameRoomInfo->win_lose-$value->Revenue;
|
|
|
|
|
+// $gameRoomInfo->pay_win_lose = $gameRoomInfo->pay_win_lose-$value->pay_Revenue;
|
|
|
|
|
+// $gameRoomInfo->Revenue = $gameRoomInfo->Revenue-$value->Revenue; //真是税收收入
|
|
|
|
|
+// $gameRoomInfo->pay_Revenue = $gameRoomInfo->pay_Revenue-$value->pay_Revenue; //真是税收收入
|
|
|
|
|
+// }
|
|
|
|
|
|
|
|
|
|
|
|
|
$value->win_lose = is_null($value->win_lose) ? 0 : number_float($value->win_lose / NumConfig::NUM_VALUE);
|
|
$value->win_lose = is_null($value->win_lose) ? 0 : number_float($value->win_lose / NumConfig::NUM_VALUE);
|
|
|
$value->pay_win_lose = is_null($value->pay_win_lose) ? 0 : number_float($value->pay_win_lose / NumConfig::NUM_VALUE);
|
|
$value->pay_win_lose = is_null($value->pay_win_lose) ? 0 : number_float($value->pay_win_lose / NumConfig::NUM_VALUE);
|
|
|
|
|
+
|
|
|
|
|
+ $value->free_win_lose = $value->win_lose-$value->pay_win_lose;
|
|
|
foreach ($gameServerNames as $serverName) {
|
|
foreach ($gameServerNames as $serverName) {
|
|
|
if ($value->GameID == $serverName->GameID && $value->SortID == $serverName->SortID) {
|
|
if ($value->GameID == $serverName->GameID && $value->SortID == $serverName->SortID) {
|
|
|
$value->ServerName = $serverName->RoomName;
|
|
$value->ServerName = $serverName->RoomName;
|
|
@@ -717,26 +727,26 @@ class GlobalUser extends BaseApiLogic
|
|
|
$value->win_lose = is_null($val->Winlost) ? $value->win_lose : $value->win_lose + ($val->Winlost / NumConfig::NUM_VALUE);
|
|
$value->win_lose = is_null($val->Winlost) ? $value->win_lose : $value->win_lose + ($val->Winlost / NumConfig::NUM_VALUE);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
- if($value->SortID == 1){
|
|
|
|
|
- $chu += $value->flowing_water;
|
|
|
|
|
- $chu_n += $value->flowing_water_new;
|
|
|
|
|
- }
|
|
|
|
|
- if($value->SortID == 2){
|
|
|
|
|
- $zhong += $value->flowing_water;
|
|
|
|
|
- $zhong_n += $value->flowing_water_new;
|
|
|
|
|
- }
|
|
|
|
|
- if($value->SortID == 3){
|
|
|
|
|
- $gao += $value->flowing_water;
|
|
|
|
|
- $gao_n += $value->flowing_water_new;
|
|
|
|
|
- }
|
|
|
|
|
|
|
+// if($value->SortID == 1){
|
|
|
|
|
+// $chu += $value->flowing_water;
|
|
|
|
|
+// $chu_n += $value->flowing_water_new;
|
|
|
|
|
+// }
|
|
|
|
|
+// if($value->SortID == 2){
|
|
|
|
|
+// $zhong += $value->flowing_water;
|
|
|
|
|
+// $zhong_n += $value->flowing_water_new;
|
|
|
|
|
+// }
|
|
|
|
|
+// if($value->SortID == 3){
|
|
|
|
|
+// $gao += $value->flowing_water;
|
|
|
|
|
+// $gao_n += $value->flowing_water_new;
|
|
|
|
|
+// }
|
|
|
if(!isset($gamesorts[$value->GameID.'-'.$value->SortID])) {
|
|
if(!isset($gamesorts[$value->GameID.'-'.$value->SortID])) {
|
|
|
- $gamesorts[$value->GameID.'-'.$value->SortID]=(object)['Cnt'=>0,'Revenue'=>0,'pay_Cnt'=>0,'pay_Revenue'=>0,'flowing_water'=>0,'win_lose'=>0,'flowing_water_new'=>0,'pay_win_lose'=>0,'pay_flowing_water_new'=>0,'GameID'=>$value->GameID,'SortID'=>$value->SortID,'DateID'=>$value->DateID,'ServerName'=>$value->ServerName];
|
|
|
|
|
|
|
+ $gamesorts[$value->GameID.'-'.$value->SortID]=(object)['Cnt'=>0,'Revenue'=>0,'pay_Cnt'=>0,'pay_Revenue'=>0,'flowing_water'=>0,'free_win_lose' => 0,'free_flowing_water' => 0,'win_lose'=>0,'flowing_water_new'=>0,'pay_win_lose'=>0,'pay_flowing_water_new'=>0,'GameID'=>$value->GameID,'SortID'=>$value->SortID,'DateID'=>$value->DateID,'ServerName'=>$value->ServerName];
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
$oldvalue = &$gamesorts[$value->GameID.'-'.$value->SortID];
|
|
$oldvalue = &$gamesorts[$value->GameID.'-'.$value->SortID];
|
|
|
|
|
|
|
|
$oldvalue->Cnt += $value->Cnt;
|
|
$oldvalue->Cnt += $value->Cnt;
|
|
|
- $oldvalue->Revenue += $value->Revenue;
|
|
|
|
|
|
|
+// $oldvalue->Revenue += $value->Revenue;
|
|
|
$oldvalue->flowing_water += $value->flowing_water;
|
|
$oldvalue->flowing_water += $value->flowing_water;
|
|
|
$oldvalue->flowing_water_new += $value->flowing_water_new;
|
|
$oldvalue->flowing_water_new += $value->flowing_water_new;
|
|
|
$oldvalue->win_lose += $value->win_lose;
|
|
$oldvalue->win_lose += $value->win_lose;
|
|
@@ -747,9 +757,15 @@ class GlobalUser extends BaseApiLogic
|
|
|
$oldvalue->pay_flowing_water_new += $value->pay_flowing_water_new;
|
|
$oldvalue->pay_flowing_water_new += $value->pay_flowing_water_new;
|
|
|
$oldvalue->pay_win_lose += $value->pay_win_lose;
|
|
$oldvalue->pay_win_lose += $value->pay_win_lose;
|
|
|
|
|
|
|
|
|
|
+ $oldvalue->free_win_lose += $value->free_win_lose;
|
|
|
|
|
+ $oldvalue->free_flowing_water += $value->free_flowing_water;
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
$gameList=array_values($gamesorts);
|
|
$gameList=array_values($gamesorts);
|
|
|
$gameList=Util::arraySort($gameList,'flowing_water_new',SORT_DESC);
|
|
$gameList=Util::arraySort($gameList,'flowing_water_new',SORT_DESC);
|
|
|
|
|
+ if(@$_REQUEST['nienie']){
|
|
|
|
|
+ dd($gameList,$gameRoomInfo);
|
|
|
|
|
+ }
|
|
|
if($chu==0)$chu=1;
|
|
if($chu==0)$chu=1;
|
|
|
$zhongRate = (ceil($zhong/$chu*100)/100);
|
|
$zhongRate = (ceil($zhong/$chu*100)/100);
|
|
|
$gaoRate = (ceil($gao/$chu*100)/100);
|
|
$gaoRate = (ceil($gao/$chu*100)/100);
|