From 3c2fec2122f4c132ea1a29947489fd3a0ab8d5a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B6=85=E7=BA=A7=E8=80=81=E7=99=BD=E5=85=94?= Date: Mon, 27 Oct 2025 10:38:39 +0800 Subject: [PATCH] Refactor MessageRecord component to replace ckchat store with customer store for improved data handling. This change enhances the retrieval of customer information based on the wechatAccountId, streamlining the message processing logic. --- .../ChatWindow/components/MessageRecord/index.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx b/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx index 5ac5eaf8..5a4fab16 100644 --- a/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx +++ b/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx @@ -13,7 +13,7 @@ import { getEmojiPath } from "@/components/EmojiSeclection/wechatEmoji"; import styles from "./com.module.scss"; import { useWeChatStore } from "@/store/module/weChat/weChat"; import { useContactStore } from "@/store/module/weChat/contacts"; -import { useCkChatStore } from "@/store/module/ckchat/ckchat"; +import { useCustomerStore } from "@weChatStore/customer"; import { fetchReCallApi, fetchVoiceToTextApi } from "./api"; import TransmitModal from "./components/TransmitModal"; @@ -45,8 +45,8 @@ const MessageRecord: React.FC = ({ contract }) => { const prevMessagesRef = useRef(currentMessages); const updateShowCheckbox = useWeChatStore(state => state.updateShowCheckbox); const updateEnterModule = useWeChatStore(state => state.updateEnterModule); - const currentKf = useCkChatStore(state => - state.kfUserList.find(kf => kf.id === contract.wechatAccountId), + const currentKf = useCustomerStore(state => + state.customerList.find(kf => kf.id === contract.wechatAccountId), ); const updateSelectedChatRecords = useWeChatStore(