房间小时榜相关

This commit is contained in:
2025-09-29 20:06:47 +08:00
parent edf7adfdab
commit 6e86199ea5
2 changed files with 22 additions and 71 deletions

View File

@@ -850,7 +850,16 @@ class Room extends Model
}
$xlh_info['xlh_info'] = model('BlindBoxTurntableGift')->get_user_xlh_info($room_id);
$open_time = db::name('vs_hour_ranking_config')->order('id', 'desc')->value('open_time');
if($open_time > 0){
if($open_time <= time()){
$hour_open = 1;//开启
}else{
$hour_open = 0;//关闭
}
}else{
$hour_open = 0;//关闭
}
return ['code' => 1,
'msg' => '成功',
'data' => ['room_info' => $room_info,
@@ -864,6 +873,7 @@ class Room extends Model
'song_pit_list' => $song_pit_list,
'friend_info' => $friend,
'gift_cycle' => $xlh_info,
'hour_ranking_open' => $hour_open
]
];
}
@@ -2006,6 +2016,16 @@ class Room extends Model
}
$xlh_info['xlh_info'] = model('BlindBoxTurntableGift')->get_user_xlh_info($room_id);
$open_time = db::name('vs_hour_ranking_config')->order('id', 'desc')->value('open_time');
if($open_time > 0){
if($open_time <= time()){
$hour_open = 1;//开启
}else{
$hour_open = 0;//关闭
}
}else{
$hour_open = 0;//关闭
}
return ['code' => 1,
'msg' => '成功',
@@ -2020,6 +2040,7 @@ class Room extends Model
'song_pit_list'=>$song_pit_list,
'friend_info' => $friend,
'gift_cycle' => $xlh_info,
'hour_ranking_open' => $hour_open
]
];
}