测试
This commit is contained in:
@@ -71,9 +71,9 @@ class GatewayClientService
|
||||
/**
|
||||
* 发送消息给指定用户
|
||||
*/
|
||||
public function sendToUser(int $toUserId, int $fromUserId, string $fromUserName, string $msgData): void
|
||||
public function sendToUser(int $toUserId, int $fromUserId, string $fromUserName, string $msgData, string $type = 'chat'): void
|
||||
{
|
||||
$message = $this->buildMessage($fromUserId, $fromUserName, $msgData);
|
||||
$message = $this->buildMessage($fromUserId, $fromUserName, $msgData, $type);
|
||||
Gateway::sendToUid($toUserId, $message);
|
||||
}
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ class ImService extends BaseService
|
||||
$this->userId === 1? 2: 1,
|
||||
$this->userId,
|
||||
$this->userInfo['nick_name'],
|
||||
json_encode($data),
|
||||
$data['content'],
|
||||
);
|
||||
return ['发送成功'];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user