添加日志

feat-im-0607-ch
ch 3 years ago
parent bfb80faaf5
commit 4dbd221a3d

@ -2,7 +2,7 @@
* @Author: ch * @Author: ch
* @Date: 2022-05-18 14:54:47 * @Date: 2022-05-18 14:54:47
* @LastEditors: ch * @LastEditors: ch
* @LastEditTime: 2022-06-09 12:23:24 * @LastEditTime: 2022-06-10 10:10:21
* @Description: file content * @Description: file content
*/ */
import '@/utils/poto-req'; import '@/utils/poto-req';
@ -172,6 +172,7 @@ class MsbIm {
if (data[this.option.ioKey] || data.code !== 200) { if (data[this.option.ioKey] || data.code !== 200) {
return false; return false;
} }
console.log('[im] 主动接收的消息', data);
let ctx = data.content; let ctx = data.content;
let historyData = [...this.sessionData], let historyData = [...this.sessionData],
newData = []; newData = [];
@ -194,9 +195,10 @@ class MsbIm {
fromAvatar: ctx.fromAvatar, fromAvatar: ctx.fromAvatar,
fromId: ctx.fromId, fromId: ctx.fromId,
fromNickname: ctx.fromNickname, fromNickname: ctx.fromNickname,
id: ctx.id, id: ctx.sessionId,
lastMessage: ctx, lastMessage: ctx,
messageList: [ctx], messageList: [ctx],
updateTimeStamp: ctx.createTimeStamp,
unreadCount: 1, unreadCount: 1,
}, },
]; ];

Loading…
Cancel
Save