改群名

This commit is contained in:
2025-12-04 17:59:38 +08:00
parent d23305cf3d
commit 37df98db10
4 changed files with 103 additions and 80 deletions

View File

@@ -271,20 +271,20 @@ namespace extend\chat\model;
$str_uid = self::getUid($grep['user_id'], $user_type);
// 如果发送的是优惠券,检查这个人有没有领取过
if($message['msg_type'] == 4 && !empty($message['coupon']) && !empty($message['chat_coupon_id'])) {
// 查询有没有领取过优惠券
$mk_shop_coupon_record = Db::name('mk_shop_coupon_record')->where([
'source' => '群聊发放',
'source_id ' => $message['chat_coupon_id'],
'user_id' => $grep['user_id'],
'shop_id' => $message['shop_id'],
])->find();
if($mk_shop_coupon_record) {
$notice_data['coupon_claim'] = 1;
}else {
$notice_data['coupon_claim'] = 0;
}
}
// if($message['msg_type'] == 4 && !empty($message['coupon']) && !empty($message['chat_coupon_id'])) {
// // 查询有没有领取过优惠券
// $mk_shop_coupon_record = Db::name('mk_shop_coupon_record')->where([
// 'source' => '群聊发放',
// 'source_id ' => $message['chat_coupon_id'],
// 'user_id' => $grep['user_id'],
// 'shop_id' => $message['shop_id'],
// ])->find();
// if($mk_shop_coupon_record) {
// $notice_data['coupon_claim'] = 1;
// }else {
// $notice_data['coupon_claim'] = 0;
// }
// }
// 群成员是否在线,在线发 不在线存起来等上线了发 免打扰也不发消息
if($grep['is_dist'] == 0) {
if(Gateway::isUidOnline($str_uid)) {