From 4fc571e5e2b0396b3fb11b52a9619b1c69013377 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E5=8D=8E=E6=B8=85?= <18691022700@163.com> Date: Wed, 13 Aug 2025 10:13:01 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8B=8D=E5=8D=96=E6=A8=A1=E5=BC=8F=E4=B8=8B?= =?UTF-8?q?=20=20=E5=90=8C=E6=84=8F=E4=B8=8A=E9=BA=A6=20=E8=BF=87=E6=BB=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/api/model/RoomPit.php | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/application/api/model/RoomPit.php b/application/api/model/RoomPit.php index c80c9a5..6876605 100644 --- a/application/api/model/RoomPit.php +++ b/application/api/model/RoomPit.php @@ -534,6 +534,20 @@ class RoomPit extends Model model('Chat')->sendMsg(1034,$room_id,$text); return ['code' => 1, 'msg' => '上麦成功', 'data' => null]; }elseif($apply_type == 3){ + if(count($to_user) >= 2){ + return ['code' => 0, 'msg' => '拍卖模式下只能一个人上麦', 'data' => null]; + } + //拍卖房当前到哪一步了 + $step = db::name('vs_room_auction')->where(['room_id' => $room_id])->order('auction_id desc')->value('status'); + if($step == 2){ + return ['code' => 0, 'msg' => '拍卖已经开始', 'data' => null]; + } + //拍卖位上有人吗 + $paimai_user = Cache::get('auction_user_'.$room_id); + if($paimai_user){ + //有人就让他下麦 + return ['code' => 0, 'msg' => '拍卖位上已有人,请先抱对方下麦', 'data' => null]; + } $i = 0; foreach ($to_user as &$value) { $i++;