小时榜

This commit is contained in:
2025-12-22 19:23:15 +08:00
parent a60937297b
commit d03e1285e4

View File

@@ -118,24 +118,28 @@ class RoomHourRanking extends Model
->whereBetween('b.createtime', [$start_time, $end_time])
->find();
if($profit[$k] != null) {
if(!empty($profit[$k])) {
$profit[$k]['total_price'] = $profit[$k]['total_price'] * get_system_config_value('coin_charm_exp');
// 查询巡乐会状态
if($room_id > 0 && $is_open_xlh == 1){
$xlh_status = model('BlindBoxTurntableGift')->get_user_xlh_info($room_id);
$profit[$k]['xlh_status'] = $xlh_status['xlh_status'];
}else{
$profit[$k]['xlh_status'] = $xlh_status['xlh_status'] ?? 0;
} else {
$profit[$k]['xlh_status'] = 0;
}
//查询房间是否有红包
if($room_id){
$red_pack_status = Db::name('redpacket')->where(['room_id' => $room_id, 'status' => ['<=',1]])->count();
// 查询房间红包状态
if($room_id > 0){
$red_pack_status = Db::name('redpacket')->where(['room_id' => $room_id, 'status' => ['<=', 1]])->count();
$profit[$k]['redpacket_status'] = $red_pack_status;
}else{
} else {
$profit[$k]['redpacket_status'] = 0;
}
} else {
unset($profit[$k]);
}
}
}