diff --git a/src/components/OrderProfile.jsx b/src/components/OrderProfile.jsx index 60b6303..87aef9b 100644 --- a/src/components/OrderProfile.jsx +++ b/src/components/OrderProfile.jsx @@ -20,7 +20,7 @@ import { import { InboxIcon, MailCheckIcon, MailUnreadIcon, SendPlaneFillIcon } from '@/components/Icons' import { useOrderStore, OrderLabelDefaultOptions, OrderStatusDefaultOptions, remindStatusOptions, fetchSetRemindStateAction, remindStatusOptionsMapped } from "@/stores/OrderStore"; import { copy, isEmpty } from "@/utils/commons"; -const OrderProfile = (props) => { +const OrderProfile = ({coliSN, ...props}) => { const orderLabelOptions = copy(OrderLabelDefaultOptions); orderLabelOptions.unshift({ value: 0, label: "未设置", disabled: true }); diff --git a/src/views/orders/Follow.jsx b/src/views/orders/Follow.jsx index 8cceef6..544736a 100644 --- a/src/views/orders/Follow.jsx +++ b/src/views/orders/Follow.jsx @@ -133,9 +133,11 @@ function Follow() { const handleTreeSelectGetMails = (selectedKeys, { node }) => { // console.info('selectedTreeKeys: ', node) const treeNode = pick(node, ['key', 'parent', 'iconIndex', 'getMails', 'title', 'parentTitle', 'parentIconIndex' ]); - setMailboxActiveNode({...treeNode, ...node._raw, OPI_SN: currentMailboxOPI}); - // const { COLI_SN, VKey, VParent, ApplyDate, OrderSourceType, IsTrue } = node?._raw || {} - setActiveEmailId(0); + const { COLI_SN, VKey, VParent, ApplyDate, OrderSourceType, IsTrue } = node?._raw || {} + if (VKey && !(!IsTrue && !COLI_SN)) { + setMailboxActiveNode({...treeNode, ...node._raw, OPI_SN: currentMailboxOPI}); + setActiveEmailId(0); + } } useEffect(() => { @@ -160,7 +162,7 @@ function Follow() { title: '今日任务', key: key + '-today', getMails: false,iconIndex: 'star', - icon: , _raw: {COLI_SN: 0}, + icon: , _raw: {COLI_SN: 0, IsTrue: 0,}, children: (sticky[0] || []).map((o) => ({ key: `today-${o.COLI_SN}`, title: `(${todoTypes[o.coli_ordertype] || o.COLI_State}) ${o.COLI_ID}`, @@ -175,7 +177,7 @@ function Follow() { title: '待办任务', key: key + '-todo', getMails: false,iconIndex: 'calendar', - icon: ,_raw: {COLI_SN: 0}, + icon: ,_raw: {COLI_SN: 0, IsTrue: 0,}, children: (sticky[1] || []).map((o) => ({ key: `todo-${o.COLI_SN}`, title: `(${todoTypes[o.coli_ordertype] || o.COLI_State}) ${o.COLI_ID}`,