登录后可接受到消息提醒,接受不到加入一对一会话提醒。
被邀请接入会话
this.$client.on(Event.INVITED, function invitedEventHandler(payload, conversation) {
console.log(1)
console.log(payload.invitedBy, conversation.id);
console.log('你被加入聊天')
})
收到消息
this.$client.on(Event.MESSAGE, function(message, conversation) {
console.log('收到新消息:' + message.text);
that.sessionContent.push({
source: 'otherSide',
content: message.text
})
that.getList()
});