From 8eab29e879f41034b2b1b4ca6ec73399686e85a4 Mon Sep 17 00:00:00 2001 From: Lei OT Date: Tue, 5 Nov 2024 13:43:52 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=88=9B=E5=BB=BA=E4=BC=9A=E8=AF=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/hooks/useConversation.js | 2 +- src/views/Conversations/Online/ConversationsNewItem.jsx | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/hooks/useConversation.js b/src/hooks/useConversation.js index 3c22546..19b768a 100644 --- a/src/hooks/useConversation.js +++ b/src/hooks/useConversation.js @@ -49,7 +49,7 @@ export function useConversationNewItem() { guest_phone: body.phone_number || '', guest_name: body.name || '', } - const createdNew = await postNewOrEditConversationItem({ ...newChat, opi_sn: opisn || userId, conversationid }); + const createdNew = await postNewOrEditConversationItem({ ...newChat, opisn: opisn || userId, conversationid }); // addToConversationList([{...createdNew, sn: createdNew.conversationid}]); const _list = await fetchConversationsList({ opisn }); addToConversationList(_list); diff --git a/src/views/Conversations/Online/ConversationsNewItem.jsx b/src/views/Conversations/Online/ConversationsNewItem.jsx index 758c823..b56a655 100644 --- a/src/views/Conversations/Online/ConversationsNewItem.jsx +++ b/src/views/Conversations/Online/ConversationsNewItem.jsx @@ -125,7 +125,8 @@ export const ConversationItemFormModal = ({ open, onCreate, onCancel, initialVal // formInstance?.resetFields(); setNewItemLoading(true); - if (initialValues.is_current_order !== true) newConversation({...values, conversationid: _initialValues?.sn || '', opi_sn: userId}); + // if (initialValues.is_current_order !== true) + newConversation({...values, conversationid: _initialValues?.sn || '', opi_sn: userId}); if (typeof onCreate === 'function') { onCreate(values); }