feat(weChat): 添加联系人存在检查逻辑并优化消息处理

在setCurrentContact方法中添加isExist参数,用于区分新增联系人和已存在联系人的处理逻辑
优化消息处理流程,确保未读消息计数正确更新
This commit is contained in:
超级老白兔
2025-09-03 18:33:05 +08:00
parent 7bd7bd3564
commit df0bbddbd5
3 changed files with 20 additions and 8 deletions

View File

@@ -13,7 +13,7 @@ const MessageList: React.FC<MessageListProps> = () => {
const { setCurrentContact, currentContract } = useWeChatStore();
const chatSessions = useCkChatStore(state => state.chatSessions);
const onContactClick = (session: ContractData | weChatGroup) => {
setCurrentContact(session);
setCurrentContact(session, true);
};
return (
<div className={styles.messageList}>