From ee8b00e8403882211be7b689bf9909d270b75469 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, 15 Oct 2025 14:19:11 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A8=E9=80=81=20=E9=87=8D=E6=96=B0?= =?UTF-8?q?=E5=AE=9A=E4=B9=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/common/model/Redpacket.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/application/common/model/Redpacket.php b/application/common/model/Redpacket.php index fab77c2..e4044a2 100644 --- a/application/common/model/Redpacket.php +++ b/application/common/model/Redpacket.php @@ -128,13 +128,18 @@ class Redpacket extends Model $data['redpacket_id'] = $redpacketId; $data['start_time'] = $startTime;//红包开抢时间 $data['redpacket_time'] = get_system_config_value('red_packet_time');//展示时间 + $data['room_name'] = Db::name('vs_room')->where('id', $data['room_id'])->value('room_name'); $text = [ 'redpacketInfo' => $data, 'text' => '' ]; model('api/Chat')->sendMsg(1060,$data['room_id'],$text); $push = new Push(UID, $data['room_id']); - $push->redpacketArrive($data); + $texts = [ + 'room_id' => $data['room_id'], + 'text' => $data['nickname'].'在'.$data['room_name'].'房间发了一个红包!' + ]; + $push->redpacketArrive($texts); return ['code' => 1, 'msg' => '发红包成功', 'data' => $redpacketId];