新需求-活动需求-盲盒转盘调通盘-调试
This commit is contained in:
@@ -762,7 +762,7 @@ class BlindBoxTurntableGiftDrawWorld extends Model
|
|||||||
if(!$pan_xlh_id){
|
if(!$pan_xlh_id){
|
||||||
return ['code' => 0, 'msg' => '创建巡乐会失败!', 'data' => []];
|
return ['code' => 0, 'msg' => '创建巡乐会失败!', 'data' => []];
|
||||||
}
|
}
|
||||||
db::name("vs_room")->where('id',$room_id)->setInc('xlh_periods');//修改巡乐会期数
|
db::name("vs_gift_bag")->where('id',13)->setInc('periods');//修改巡乐会期数
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private function updateAndPushXlhStatus($room_id, $xlh_ext, $currentXlhPeriodsNum){
|
private function updateAndPushXlhStatus($room_id, $xlh_ext, $currentXlhPeriodsNum){
|
||||||
@@ -990,7 +990,7 @@ class BlindBoxTurntableGiftDrawWorld extends Model
|
|||||||
|
|
||||||
// 3. 检查巡乐会状态
|
// 3. 检查巡乐会状态
|
||||||
$pan_xlh = db::name('vs_room_pan_xlh')
|
$pan_xlh = db::name('vs_room_pan_xlh')
|
||||||
->where(['periods' => $bag_data['periods'],"send_time"=>0])
|
->where(['periods' => $bag_data['periods']])
|
||||||
->find();
|
->find();
|
||||||
if (empty($pan_xlh)) {
|
if (empty($pan_xlh)) {
|
||||||
return ['code' => 0, 'msg' => '未开始', 'data' => null];
|
return ['code' => 0, 'msg' => '未开始', 'data' => null];
|
||||||
@@ -1155,6 +1155,7 @@ class BlindBoxTurntableGiftDrawWorld extends Model
|
|||||||
$last_update = end($main_prize_updates);
|
$last_update = end($main_prize_updates);
|
||||||
db::name('vs_room_pan_xlh')->where('id', $pan_xlh['id'])->update([
|
db::name('vs_room_pan_xlh')->where('id', $pan_xlh['id'])->update([
|
||||||
'user_id' => $last_update['user_id'],
|
'user_id' => $last_update['user_id'],
|
||||||
|
'room_id' => $room_id,
|
||||||
'pay_price' => $ext['xlh_box_price'],
|
'pay_price' => $ext['xlh_box_price'],
|
||||||
'locking_gift_id' => $last_update['gift_id'],
|
'locking_gift_id' => $last_update['gift_id'],
|
||||||
'num' => $last_update['num'],
|
'num' => $last_update['num'],
|
||||||
@@ -1165,6 +1166,7 @@ class BlindBoxTurntableGiftDrawWorld extends Model
|
|||||||
db::name('vs_room_pan_xlh_log')->insert([
|
db::name('vs_room_pan_xlh_log')->insert([
|
||||||
'xlh_id' => $pan_xlh['id'],
|
'xlh_id' => $pan_xlh['id'],
|
||||||
'user_id' => $last_update['user_id'],
|
'user_id' => $last_update['user_id'],
|
||||||
|
'room_id' => $room_id,
|
||||||
'num' => $last_update['num'],
|
'num' => $last_update['num'],
|
||||||
'locking_end_time' => $last_update['end_time'],
|
'locking_end_time' => $last_update['end_time'],
|
||||||
'createtime' => time()
|
'createtime' => time()
|
||||||
|
|||||||
@@ -174,14 +174,10 @@ class RoomPan
|
|||||||
echo "处理发放记录失败 \n";
|
echo "处理发放记录失败 \n";
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
db::name("vs_room")->where('id',$value['room_id'])->update([
|
|
||||||
'xlh_periods_num' => 0
|
|
||||||
]);
|
|
||||||
//推送
|
//推送
|
||||||
$FromUserInfo = db::name('user')->field('nickname,avatar')->where(['id'=>$value['user_id']])->find();
|
$FromUserInfo = db::name('user')->field('nickname,avatar')->where(['id'=>$value['user_id']])->find();
|
||||||
$room_name = db::name('vs_room')->where(['id'=>$value['room_id']])->value('room_name');
|
|
||||||
$gift_name = db::name('vs_gift')->where(['gid'=>$value['gift_id']])->value('gift_name');
|
$gift_name = db::name('vs_gift')->where(['gid'=>$value['gift_id']])->value('gift_name');
|
||||||
$text = $FromUserInfo['nickname'] . ' 用户在 ' . $room_name.' 房间巡乐会中 ' .$gift_name.'礼物 x ' .$value['num']." 已收入背包";
|
$text = $FromUserInfo['nickname'] . ' 用户在巡乐会中 ' .$gift_name.'礼物 x ' .$value['num']." 已收入背包";
|
||||||
//推送礼物横幅
|
//推送礼物横幅
|
||||||
$push = new Push(0, $value['room_id']);
|
$push = new Push(0, $value['room_id']);
|
||||||
$text_list_new = [
|
$text_list_new = [
|
||||||
|
|||||||
Reference in New Issue
Block a user