mirror of
https://github.com/kuaifan/dootask.git
synced 2026-03-17 11:13:26 +00:00
perf: 消息也推送给在其它地方登录的自己
This commit is contained in:
parent
4f5dce282b
commit
a6150821e7
@ -48,13 +48,10 @@ class WebSocketDialogMsgTask extends AbstractTask
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 推送目标①:群成员
|
// 推送目标①:会话成员/群成员
|
||||||
$array = [];
|
$array = [];
|
||||||
$userids = $dialog->dialogUser->pluck('userid')->toArray();
|
$userids = $dialog->dialogUser->pluck('userid')->toArray();
|
||||||
foreach ($userids AS $userid) {
|
foreach ($userids AS $userid) {
|
||||||
if ($userid == $msg->userid) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
$mention = preg_match("/<span class=\"mention user\" data-id=\"[0|{$userid}]\">/", $msg->type === 'text' ? $msg->msg['text'] : '');
|
$mention = preg_match("/<span class=\"mention user\" data-id=\"[0|{$userid}]\">/", $msg->type === 'text' ? $msg->msg['text'] : '');
|
||||||
WebSocketDialogMsgRead::createInstance([
|
WebSocketDialogMsgRead::createInstance([
|
||||||
'dialog_id' => $msg->dialog_id,
|
'dialog_id' => $msg->dialog_id,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user