|
|
@@ -196,7 +196,7 @@ class PlayerControl extends BaseController
|
|
|
}
|
|
|
if($isFindUserId) {
|
|
|
$merchantsUserIds = MerchantsUserModel::getPlayerListByIds($userInfo['merchant_id'], $where, ['user_id']);
|
|
|
- $controlWhere[] = ['user_id', 'in', $merchantsUserIds];
|
|
|
+ $controlWhere[] = ['user_id', 'in', array_column($merchantsUserIds, 'user_id')];
|
|
|
}
|
|
|
|
|
|
if(!empty($filters['game_id'])) {
|
|
|
@@ -215,9 +215,13 @@ class PlayerControl extends BaseController
|
|
|
$allGameList = GameModel::getGames($userInfo['merchant_id'], [], ['id', 'game_id', 'title', 'game_platform']);
|
|
|
$gameConfig = array_column($allGameList, null, 'game_id');
|
|
|
|
|
|
- $player_id = array_column($results['list'], 'player_id');
|
|
|
+ $player_ids = array_column($results['list'], 'player_id');
|
|
|
|
|
|
- $userListBalance = CommonMerchantUserAndBalance::getMerchantUserBalance($player_id);
|
|
|
+ $playerConfig = CommonMerchantUserAndBalance::getMerchantUser($player_ids, ['user_id','uname','nickname']);
|
|
|
+ $playerConfig = array_column($playerConfig, null, 'user_id');
|
|
|
+
|
|
|
+
|
|
|
+ $userListBalance = CommonMerchantUserAndBalance::getMerchantUserBalance($player_ids);
|
|
|
$userBalanceConfig = [];
|
|
|
foreach ($userListBalance as $item) {
|
|
|
$userBalanceConfig[$item['user_id']] = $item['balance'];
|
|
|
@@ -263,6 +267,10 @@ class PlayerControl extends BaseController
|
|
|
$item['old_rtp'] = bcdiv($item['old_rtp'], 100, 2) . "%";
|
|
|
$item['now_rtp'] = bcdiv($rtpConfigList[$one_key] ?? 0, 100, 2) . "%";
|
|
|
|
|
|
+ $playerInfo = $playerConfig[$player_id] ?? [];
|
|
|
+ $item['uname'] = $playerInfo['uname'] ?? '';
|
|
|
+ $item['nickname'] = $playerInfo['nickname'] ?? '';
|
|
|
+
|
|
|
unset($item['app_id']);
|
|
|
unset($item['game_id']);
|
|
|
unset($item['bet_amount']);
|