modelfix-4
This commit is contained in:
parent
18c0693550
commit
db358f80fd
|
@ -97,8 +97,8 @@ export const InboxView = () => {
|
||||||
const handleSubmit = async (message: string) => {
|
const handleSubmit = async (message: string) => {
|
||||||
await sendMessage({
|
await sendMessage({
|
||||||
body: message,
|
body: message,
|
||||||
chat: currentDialog().id.toString(),
|
chat_id: currentDialog().id.toString(),
|
||||||
replyTo: messageToReply()?.id
|
reply_to: messageToReply()?.id
|
||||||
})
|
})
|
||||||
setClear(true)
|
setClear(true)
|
||||||
setMessageToReply(null)
|
setMessageToReply(null)
|
||||||
|
@ -131,7 +131,7 @@ export const InboxView = () => {
|
||||||
|
|
||||||
const chatsToShow = () => {
|
const chatsToShow = () => {
|
||||||
const sorted = chats().sort((a, b) => {
|
const sorted = chats().sort((a, b) => {
|
||||||
return b.updatedAt - a.updatedAt
|
return b.updated_at - a.updated_at
|
||||||
})
|
})
|
||||||
if (sortByPerToPer()) {
|
if (sortByPerToPer()) {
|
||||||
return sorted.filter((chat) => (chat.title || '').trim().length === 0)
|
return sorted.filter((chat) => (chat.title || '').trim().length === 0)
|
||||||
|
@ -239,7 +239,7 @@ export const InboxView = () => {
|
||||||
isOpened={chat.id === currentDialog()?.id}
|
isOpened={chat.id === currentDialog()?.id}
|
||||||
members={chat.members}
|
members={chat.members}
|
||||||
ownId={currentUserId()}
|
ownId={currentUserId()}
|
||||||
lastUpdate={chat.updatedAt}
|
lastUpdate={chat.updated_at}
|
||||||
counter={chat.unread}
|
counter={chat.unread}
|
||||||
message={chat.messages.pop()?.body}
|
message={chat.messages.pop()?.body}
|
||||||
/>
|
/>
|
||||||
|
@ -283,7 +283,7 @@ export const InboxView = () => {
|
||||||
content={message}
|
content={message}
|
||||||
ownId={currentUserId()}
|
ownId={currentUserId()}
|
||||||
members={currentDialog().members}
|
members={currentDialog().members}
|
||||||
replyBody={message.replyTo && findToReply(message.replyTo).body}
|
replyBody={message.reply_to && findToReply(message.reply_to).body}
|
||||||
replyClick={() => setMessageToReply(message)}
|
replyClick={() => setMessageToReply(message)}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user