|
|
@ -239,7 +239,7 @@ class Im extends BaseController |
|
|
$atList=(new Message())->where(['chat_identify'=>$chat_identify,'is_group'=>1])->whereFindInSet('at',$this->userInfo['user_id'])->order('msg_id desc')->select()->toArray(); |
|
|
$atList=(new Message())->where(['chat_identify'=>$chat_identify,'is_group'=>1])->whereFindInSet('at',$this->userInfo['user_id'])->order('msg_id desc')->select()->toArray(); |
|
|
$msgIda=array_column($atList,'msg_id'); |
|
|
$msgIda=array_column($atList,'msg_id'); |
|
|
// 如果两次推送at数据的列表不一样,则推送 |
|
|
// 如果两次推送at数据的列表不一样,则推送 |
|
|
if($isPush!=json_encode($msgIda)){ |
|
|
//if($isPush!=json_encode($msgIda)){ |
|
|
$atData=$this->recombileMsg($atList,false); |
|
|
$atData=$this->recombileMsg($atList,false); |
|
|
wsSendMsg($this->userInfo['user_id'],'atMsgList',[ |
|
|
wsSendMsg($this->userInfo['user_id'],'atMsgList',[ |
|
|
'list'=>$atData, |
|
|
'list'=>$atData, |
|
|
@ -247,7 +247,7 @@ class Im extends BaseController |
|
|
'toContactId'=>$param['toContactId'] |
|
|
'toContactId'=>$param['toContactId'] |
|
|
]); |
|
|
]); |
|
|
Cache::set('atMsgPush'.$chat_identify,json_encode($msgIda),60); |
|
|
Cache::set('atMsgPush'.$chat_identify,json_encode($msgIda),60); |
|
|
} |
|
|
//} |
|
|
} |
|
|
} |
|
|
// 如果是消息管理器则不用倒序 |
|
|
// 如果是消息管理器则不用倒序 |
|
|
if (!isset($param['type'])) { |
|
|
if (!isset($param['type'])) { |
|
|
|