diff --git a/src/channel/bubbleMsgUtils.js b/src/channel/bubbleMsgUtils.js index 40b0a51..4a94608 100644 --- a/src/channel/bubbleMsgUtils.js +++ b/src/channel/bubbleMsgUtils.js @@ -541,6 +541,7 @@ export const receivedMsgTypeMapped = { getMsg: (result) => result, contentToRender: () => null, contentToUpdate: (msgcontent) => { + if (isEmpty(msgcontent)) return null; let apiErrorCode, apiErrorMsg = ''; const waCode = msgcontent.error.message.match(/\(#(\d+)\)/); diff --git a/src/views/Conversations/Online/Components/EmailContent.jsx b/src/views/Conversations/Online/Components/EmailContent.jsx index 9beb950..f4c050e 100644 --- a/src/views/Conversations/Online/Components/EmailContent.jsx +++ b/src/views/Conversations/Online/Components/EmailContent.jsx @@ -115,7 +115,6 @@ const EmailContent = ({ id, content: MailContent, ...props }) => { border: 'none', display: 'block', }} - title='Dynamic Height Iframe' sandbox='allow-scripts allow-same-origin' /> diff --git a/src/views/Conversations/Online/Components/EmailDetailInline.jsx b/src/views/Conversations/Online/Components/EmailDetailInline.jsx index 701a9e4..5262600 100644 --- a/src/views/Conversations/Online/Components/EmailDetailInline.jsx +++ b/src/views/Conversations/Online/Components/EmailDetailInline.jsx @@ -1,6 +1,6 @@ import { useState, useEffect } from 'react' import { App, Button, Divider, Avatar } from 'antd' -import { LoadingOutlined, ApiOutlined } from '@ant-design/icons'; +import { LoadingOutlined, ApiOutlined, LeftOutlined, RightOutlined } from '@ant-design/icons'; import { EditIcon, ReplyIcon, ResendIcon, ShareForwardIcon } from '@/components/Icons' import { isEmpty, TagColorStyle } from '@/utils/commons' import EmailEditorPopup from '../Input/EmailEditorPopup' @@ -14,7 +14,7 @@ import EmailContent from './EmailContent'; /** * @property {*} emailMsg - 邮件数据. { conversationid, actionId, order_opi, coli_sn, msgOrigin: { from, to, id, email: { subject, mai_sn, } } } */ -const EmailDetailInline = ({ mailID, open, setOpen = () => {}, emailMsg={}, disabled=false, ...props }) => { +const EmailDetailInline = ({ mailID, emailMsg={}, disabled=false, ...props }) => { // console.log('emailDetail', emailMsg); @@ -117,7 +117,7 @@ const EmailDetailInline = ({ mailID, open, setOpen = () => {}, emailMsg={}, disa } return ( -
+
{btns}
) @@ -130,7 +130,7 @@ const EmailDetailInline = ({ mailID, open, setOpen = () => {}, emailMsg={}, disa
-
+
{(mailData.info?.MAI_From || '').substring(0, 1)} @@ -139,7 +139,7 @@ const EmailDetailInline = ({ mailID, open, setOpen = () => {}, emailMsg={}, disa {mailData.info?.MAI_From}
-
+
{mailData.info?.MAI_SendDate || emailMsg.localDate}
diff --git a/src/views/Conversations/Online/Components/MessageListFilter.jsx b/src/views/Conversations/Online/Components/MessageListFilter.jsx index b9eb45e..70e101e 100644 --- a/src/views/Conversations/Online/Components/MessageListFilter.jsx +++ b/src/views/Conversations/Online/Components/MessageListFilter.jsx @@ -1,5 +1,5 @@ import { useEffect, useState } from 'react'; -import { App, Button, Popover, Tabs, List, Image, Avatar, Card, Flex, Space } from 'antd'; +import { App, Button, Popover, Tabs, List, Image, Avatar, Card, Flex, Space,Typography } from 'antd'; import { FileSearchOutlined, LoadingOutlined } from '@ant-design/icons'; import { RotateLeftOutlined, RotateRightOutlined, ZoomInOutlined, ZoomOutOutlined } from '@ant-design/icons' import { InboxIcon, SendPlaneFillIcon } from '@/components/Icons'; @@ -13,6 +13,7 @@ import useStyleStore from '@/stores/StyleStore'; import useAuthStore from '@/stores/AuthStore'; import { sentMsgTypeMapped } from '@/channel/bubbleMsgUtils'; import { v4 as uuid } from 'uuid'; +import dayjs from 'dayjs' const BIG_PAGE_SIZE = MESSAGE_PAGE_SIZE * 10; @@ -337,28 +338,25 @@ const MessageListFilter = ({ ...props }) => { renderItem={({ msgtext, ...item }) => ( { onOpenEmail({ msgtext, ...item }); - setOpenPopup(false); + // setOpenPopup(false); }}> - : - // - // {item.senderName.substring(0, 3)} - // - } - title={msgtext?.email?.subject} - // description={`To: ${msgtext.to}`} - description={ - -
{`To: ${msgtext.to}`}
-
{item.localDate}
-
- } - /> - {msgtext?.email?.abstract} + +
+ {item.sender !== 'me' ? : } + {/* */} + {msgtext?.email?.subject} + {/* */} +
+
+ {msgtext.to.replaceAll('"', '')} +
+
+ {dayjs(item.localDate).format('MM-DD HH:mm')} +
+
)} /> @@ -369,7 +367,7 @@ const MessageListFilter = ({ ...props }) => { return ( <> - {