盲盒转盘bug修改
This commit is contained in:
@@ -35,7 +35,7 @@ class RoomPan
|
||||
}
|
||||
echo "开始发放".count($blind_box_turntable)." \n";
|
||||
foreach ($blind_box_turntable as $k => $v) {
|
||||
$blind_box_turntable_results_log = db('vs_blind_box_turntable_results_log')->where('tid',$v['id'])->find();
|
||||
$blind_box_turntable_results_log = db('vs_blind_box_turntable_results_log')->where('tid',$v['id'])->select();
|
||||
if(empty($blind_box_turntable_results_log)){
|
||||
echo $v['id']." 没有需要发放的礼物 \n";
|
||||
continue;
|
||||
@@ -53,18 +53,21 @@ class RoomPan
|
||||
$play_image[] = $draw_gift['play_image'];
|
||||
|
||||
$text_message = $text_message . '在' . $room_name . '房间送给了' . $ToUserInfo['nickname'] . $draw_gift['gift_name'] . 'X' . $value['count']."\n";
|
||||
$text_list_new[] = [
|
||||
'text' => $text_message,
|
||||
'gift_picture' => $draw_gift['base_image'],
|
||||
'room_id' => $room_id,
|
||||
'fromUserName' => $FromUserInfo['nickname'],
|
||||
'toUserName' => $ToUserInfo['nickname'],
|
||||
'giftName' => $draw_gift['gift_name'],
|
||||
'roomId' => $room_id,
|
||||
'number' => $value['count'],
|
||||
];
|
||||
if($draw_gift['is_public_server'] == 1) {
|
||||
$text_list_new[] = [
|
||||
'text' => $text_message,
|
||||
'gift_picture' => $draw_gift['base_image'],
|
||||
'room_id' => $room_id,
|
||||
'fromUserName' => $FromUserInfo['nickname'],
|
||||
'toUserName' => $ToUserInfo['nickname'],
|
||||
'giftName' => $draw_gift['gift_name'],
|
||||
'roomId' => $room_id,
|
||||
'number' => $value['count'],
|
||||
];
|
||||
}
|
||||
}
|
||||
$text = [
|
||||
'FromUserInfo' => $FromUserInfo,
|
||||
'GiftInfo' => [
|
||||
'play_image' => implode(',',$play_image),
|
||||
],
|
||||
@@ -85,7 +88,7 @@ class RoomPan
|
||||
//聊天室推送系统消息
|
||||
model('Chat')->sendMsg(1028,$room_id,$text1);
|
||||
}else{
|
||||
if($draw_gift['is_public_server'] == 1){
|
||||
if(!empty($text_list_new)){
|
||||
//推送礼物横幅
|
||||
$push = new Push($v['user_id'], $room_id);
|
||||
$push->giftBanner($text_list_new);
|
||||
|
||||
Reference in New Issue
Block a user