fix:修改转移会话问题

feat-im-0607-ch
ch 2 years ago
parent ead3a017e1
commit 3ab876abbe

@ -2,7 +2,7 @@
* @Author: ch
* @Date: 2022-05-18 14:54:47
* @LastEditors: ch
* @LastEditTime: 2022-06-13 18:54:30
* @LastEditTime: 2022-06-13 21:32:46
* @Description: file content
*/
import '@/utils/poto-req';
@ -34,6 +34,7 @@ const fromatPotoReq = (traceId, traceType, content) => {
message: res.getMessage(),
};
};
class MsbIm {
defaultOption = {
ioKey: 'traceId',
@ -281,13 +282,12 @@ class MsbIm {
if (hisIndex >= 0) {
historyData[hisIndex].lastMessage = item.lastMessage;
historyData[hisIndex].unreadCount++;
newData.push(historyData);
newData.push(historyData[hisIndex]);
} else {
item.messageList = [];
newData = [...newData, item];
}
});
this.setSessionData(newData);
return Promise.resolve(result);
}
@ -459,5 +459,11 @@ class MsbIm {
}
return Promise.resolve(result);
}
close() {
this.socket.close();
this.socket = null;
this.isOpen = false;
this.setSessionData([]);
}
}
export default MsbIm;

@ -300,6 +300,7 @@
reason: res.value,
})
.then((res) => {
currentSessionId.value = null;
Im.setCurSessionId(null);
Im.getSessionList();
});

Loading…
Cancel
Save