diff --git a/web/frontend/src/pages/PlatformFulfillmentPage.tsx b/web/frontend/src/pages/PlatformFulfillmentPage.tsx index 451fd1f..8ff09ea 100644 --- a/web/frontend/src/pages/PlatformFulfillmentPage.tsx +++ b/web/frontend/src/pages/PlatformFulfillmentPage.tsx @@ -2,8 +2,8 @@ import { useCallback, useEffect, useRef, useState } from 'react'; import { useNavigate } from 'react-router-dom'; import dayjs from 'dayjs'; import type { Dayjs } from 'dayjs'; -import { Alert, Button, Card, Col, DatePicker, Descriptions, Drawer, Dropdown, Empty, Input, InputNumber, Modal, QRCode, Row, Segmented, Select, Space, Switch, Table, Tag, Timeline, Typography } from 'antd'; -import { CheckCircleOutlined, CopyOutlined, CreditCardOutlined, DownloadOutlined, GiftOutlined, LinkOutlined, MoreOutlined, QrcodeOutlined, ReloadOutlined, SettingOutlined, ShoppingOutlined, SyncOutlined, UndoOutlined, UserSwitchOutlined } from '@ant-design/icons'; +import { Alert, Button, Card, Col, DatePicker, Descriptions, Drawer, Empty, Input, InputNumber, Modal, QRCode, Row, Segmented, Select, Space, Switch, Table, Tag, Timeline, Typography } from 'antd'; +import { CheckCircleOutlined, CopyOutlined, CreditCardOutlined, DownloadOutlined, GiftOutlined, LinkOutlined, QrcodeOutlined, ReloadOutlined, SettingOutlined, ShoppingOutlined, SyncOutlined, UndoOutlined, UserSwitchOutlined } from '@ant-design/icons'; import type { ColumnsType } from 'antd/es/table'; import { douyuApi, platformFulfillmentApi } from '../api/modules'; import type { DouyuGoodsItem, DouyuTaskItem, PlatformFulfillmentBindingLog, PlatformFulfillmentDetail, PlatformFulfillmentMapping, PlatformFulfillmentSettings, PlatformFulfillmentTask } from '../api/modules'; @@ -2579,41 +2579,32 @@ export default function PlatformFulfillmentPage() { { title: '操作', key: 'actions', - width: 150, + width: 250, render: (_: unknown, row) => ( - + - { - if (key === 'toggle') { - runMappingAction(row, row.enabled ? 'disable' : 'enable'); - } else if (key === 'archive') { - runMappingAction(row, 'archive'); - } else if (key === 'restore') { - runMappingAction(row, 'restore'); - } else if (key === 'delete') { - removeMapping(row); - } - }, - }} - > - - + ) : ( + <> + + + + )} + ), }, @@ -2622,19 +2613,16 @@ export default function PlatformFulfillmentPage() { - setMappingEditorOpen(false)} - extra={ - - - - - } + width={620} + centered + okText="保存映射" + cancelText="取消" + confirmLoading={mappingSaving} + onOk={() => void saveMapping()} + onCancel={() => setMappingEditorOpen(false)} >
@@ -2737,7 +2725,7 @@ export default function PlatformFulfillmentPage() { description="内部 SKU 必须和 order_site 订单商品一致;商品 ID 来自斗鱼精英宝典活动。" /> - + ); }