优化体验: 缓存表单数据: 订单跟踪-高级查询

dev/chat
Lei OT 2 years ago
parent b1b2844238
commit a3285eeaec

@ -12,10 +12,10 @@ export const useFormStore = create(
// 订单跟踪页面
orderFollowForm: {
type: 'today',
orderStatus: '新状态',
orderNumber: '订单号',
orderLabel: '订单标签',
startDate: '走团时间',
// orderStatus: '新状态',
// orderNumber: '订单号',
// orderLabel: '订单标签',
// startDate: '走团时间',
},
setOrderFollowForm: (orderFollowForm) => set({ orderFollowForm }),
orderFollowAdvanceChecked: false,

@ -52,7 +52,7 @@ const AdvanceSearchForm = memo(function ({ initialValues, onSubmit }) {
layout={'vertical'}
form={form}
initialValues={{
orderLabel: '', orderStatus: '', remindState: ''
orderLabel: '', orderStatus: '', remindState: '', ...initialValues
}}
onFinish={handleSubmit}
>
@ -167,7 +167,7 @@ function OrderGroupTable({ formValues }) {
if (record.buytime > 0) regularText = '(R' + record.buytime + ')'
return (
<Space>
<Link to={`/order/chat/${record.COLI_SN}`} state={record}>{text + regularText}</Link>
<Link to={`/order/chat/${record.COLI_SN}`} state={record} title={record.coli_guest_WhatsApp}>{text + regularText}</Link>
<Badge
count={record.unread_msg}
style={{
@ -357,7 +357,7 @@ function OrderFollow() {
defaultChecked={false}
onChange={() => { toggleAdvance(!advanceChecked) }} />
</Flex>
<Conditional condition={advanceChecked} whenTrue={<AdvanceSearchForm onSubmit={handleSubmit} />}
<Conditional condition={advanceChecked} whenTrue={<AdvanceSearchForm onSubmit={handleSubmit} initialValues={formValues} />}
/>
<OrderGroupTable formValues={formValues} />
</Space>

Loading…
Cancel
Save