换房间类型 拍卖位处理

This commit is contained in:
2025-09-23 23:28:28 +08:00
parent f19efd80ea
commit 8efa22b517
2 changed files with 7 additions and 7 deletions

View File

@@ -1716,6 +1716,7 @@ class Room extends Model
foreach ($room_auction as $v){ foreach ($room_auction as $v){
model('RoomAuction')->room_auction_end($room_id,$v['auction_id']); model('RoomAuction')->room_auction_end($room_id,$v['auction_id']);
} }
}
//拍卖位上是否有人 //拍卖位上是否有人
$an = Cache::get('auction_user_'.$room_id); $an = Cache::get('auction_user_'.$room_id);
if($an){ if($an){
@@ -1723,7 +1724,6 @@ class Room extends Model
model('api/RoomPit')->host_user_pit($uid,$room_id,888,$an,2); model('api/RoomPit')->host_user_pit($uid,$room_id,888,$an,2);
} }
} }
}
if($type == 2){ if($type == 2){
//清除房间此前的魅力值 //清除房间此前的魅力值
db::name('vs_room_user_charm')->where(['room_id' => $room_id])->update(['charm' => 0,'clear_time' => time()]); db::name('vs_room_user_charm')->where(['room_id' => $room_id])->update(['charm' => 0,'clear_time' => time()]);

View File

@@ -925,7 +925,7 @@ class RoomPit extends Model
if(!$pit_number || $pit_number == 888){ if(!$pit_number || $pit_number == 888){
$roomInfo = db::name('vs_room')->where('id',$room_id)->field('label_id,type_id')->find(); $roomInfo = db::name('vs_room')->where('id',$room_id)->field('label_id,type_id')->find();
if($roomInfo['type_id'] == 2){//拍卖 if($roomInfo['type_id'] == 2 || Cache::get('auction_user_'.$room_id)){//拍卖
//查询当前是否处于拍卖中 //查询当前是否处于拍卖中
$auctioning = db::name('vs_room_auction') $auctioning = db::name('vs_room_auction')
->where(['room_id' => $room_id, 'status' => 2, 'user_id' => $accept_user_id])->find(); ->where(['room_id' => $room_id, 'status' => 2, 'user_id' => $accept_user_id])->find();