Commit 318b94d2d943fd0a3ffca27c2da25c5b38571087
Merge branch 'znh' into 'develop'
Znh See merge request !17
Showing
10 changed files
with
1044 additions
and
126 deletions
src/pages/Order/components/AfterSalesDrawer.tsx
0 → 100644
1 | +import { RESPONSE_CODE } from '@/constants/enum'; | ||
2 | +import { postServiceOrderApplyAfterSales } from '@/services'; | ||
3 | +import { enumToSelect } from '@/utils'; | ||
4 | +import { | ||
5 | + DrawerForm, | ||
6 | + ProFormDigit, | ||
7 | + ProFormSelect, | ||
8 | + ProFormTextArea, | ||
9 | +} from '@ant-design/pro-components'; | ||
10 | +import { Form, message } from 'antd'; | ||
11 | +import { AFTE_SALES_PLAN_OPTIONS } from '../constant'; | ||
12 | +export default ({ setVisible, mainOrder, subOrders, onClose }) => { | ||
13 | + let subOrderIds = subOrders?.map((item: { id: any }) => { | ||
14 | + return item.id; | ||
15 | + }); | ||
16 | + let mainOrderId = mainOrder.id; | ||
17 | + const [form] = Form.useForm<{ | ||
18 | + afterSalesNotes: string; | ||
19 | + afterSalesPlan: string; | ||
20 | + ids: []; | ||
21 | + totalPayment: number; | ||
22 | + }>(); | ||
23 | + | ||
24 | + return ( | ||
25 | + <DrawerForm<{ | ||
26 | + afterSalesNotes: string; | ||
27 | + afterSalesPlan: string; | ||
28 | + subOrderIds: []; | ||
29 | + totalPayment: number; | ||
30 | + mainId: number; | ||
31 | + }> | ||
32 | + title="申请售后" | ||
33 | + open | ||
34 | + resize={{ | ||
35 | + onResize() { | ||
36 | + console.log('resize!'); | ||
37 | + }, | ||
38 | + maxWidth: window.innerWidth * 0.8, | ||
39 | + minWidth: 500, | ||
40 | + }} | ||
41 | + form={form} | ||
42 | + autoFocusFirstInput | ||
43 | + drawerProps={{ | ||
44 | + destroyOnClose: true, | ||
45 | + onClose: () => { | ||
46 | + setVisible(false); | ||
47 | + }, | ||
48 | + }} | ||
49 | + onFinish={async (values) => { | ||
50 | + values.subOrderIds = subOrderIds; | ||
51 | + values.mainId = mainOrderId; | ||
52 | + let res = await postServiceOrderApplyAfterSales({ data: values }); | ||
53 | + if (res?.result === RESPONSE_CODE.SUCCESS) { | ||
54 | + message.success(res.message); | ||
55 | + onClose(); | ||
56 | + } | ||
57 | + }} | ||
58 | + > | ||
59 | + <ProFormSelect | ||
60 | + key="key" | ||
61 | + label="售后方案" | ||
62 | + width="lg" | ||
63 | + showSearch | ||
64 | + name="afterSalesPlan" | ||
65 | + options={enumToSelect(AFTE_SALES_PLAN_OPTIONS)} | ||
66 | + placeholder="请搜索" | ||
67 | + rules={[{ required: true, message: '售后方案必填' }]} | ||
68 | + ></ProFormSelect> | ||
69 | + <ProFormDigit | ||
70 | + width="lg" | ||
71 | + name="totalPayment" | ||
72 | + label="总金额调整" | ||
73 | + min={0} | ||
74 | + initialValue={mainOrder.totalPayment} | ||
75 | + rules={[{ required: true, message: '总金额必填' }]} | ||
76 | + /> | ||
77 | + <ProFormTextArea | ||
78 | + width="lg" | ||
79 | + label="售后原因" | ||
80 | + name="afterSalesNotes" | ||
81 | + rules={[{ required: true, message: '售后原因必填' }]} | ||
82 | + /> | ||
83 | + </DrawerForm> | ||
84 | + ); | ||
85 | +}; |
src/pages/Order/components/DeliverModal.tsx
1 | import { RESPONSE_CODE } from '@/constants/enum'; | 1 | import { RESPONSE_CODE } from '@/constants/enum'; |
2 | import { | 2 | import { |
3 | + postServiceOrderProcureSend, | ||
3 | postServiceOrderSendProduct, | 4 | postServiceOrderSendProduct, |
4 | postServiceOrderSupplierSendOrder, | 5 | postServiceOrderSupplierSendOrder, |
5 | } from '@/services'; | 6 | } from '@/services'; |
@@ -156,6 +157,8 @@ const DeliverModal = ({ | @@ -156,6 +157,8 @@ const DeliverModal = ({ | ||
156 | let res; | 157 | let res; |
157 | if (optType(CHECK_TYPE.SUPPLIER)) { | 158 | if (optType(CHECK_TYPE.SUPPLIER)) { |
158 | res = await postServiceOrderSupplierSendOrder({ data: body }); | 159 | res = await postServiceOrderSupplierSendOrder({ data: body }); |
160 | + } else if (optType(CHECK_TYPE.PROCURE)) { | ||
161 | + res = await postServiceOrderProcureSend({ data: body }); | ||
159 | } else { | 162 | } else { |
160 | res = await postServiceOrderSendProduct({ data: body }); | 163 | res = await postServiceOrderSendProduct({ data: body }); |
161 | } | 164 | } |
src/pages/Order/components/FinancialDrawer.tsx
@@ -140,6 +140,17 @@ export default ({ | @@ -140,6 +140,17 @@ export default ({ | ||
140 | ] | 140 | ] |
141 | : ''} | 141 | : ''} |
142 | 142 | ||
143 | + {/* <ProFormSelect | ||
144 | + placeholder="是否完全开票" | ||
145 | + name="invoicingType" | ||
146 | + width="lg" | ||
147 | + label="是否完全开票" | ||
148 | + options={[{label:'部分开票',value:'部分开票'},{label:'完全开票',value:'完全开票'}]} | ||
149 | + onChange={setInvoicingStatus} | ||
150 | + initialValue={'完全开票'} | ||
151 | + // disabled={mainInfoDisbled} | ||
152 | + rules={[{ required: true, message: '是否需要开票必填' }]} | ||
153 | + /> */} | ||
143 | <ProFormTextArea | 154 | <ProFormTextArea |
144 | width="lg" | 155 | width="lg" |
145 | name="invoicingNotes" | 156 | name="invoicingNotes" |
src/pages/Order/components/HistoryModal.tsx
@@ -8,10 +8,11 @@ import { | @@ -8,10 +8,11 @@ import { | ||
8 | ORDER_STATUS_OPTIONS, | 8 | ORDER_STATUS_OPTIONS, |
9 | } from '../constant'; | 9 | } from '../constant'; |
10 | 10 | ||
11 | -export default ({ subOrders, onClose }) => { | 11 | +export default ({ subOrders, isCancelledOrder, onClose }) => { |
12 | let subOrderIds = subOrders?.map((subOrder: any) => { | 12 | let subOrderIds = subOrders?.map((subOrder: any) => { |
13 | return subOrder.id; | 13 | return subOrder.id; |
14 | }); | 14 | }); |
15 | + | ||
15 | const [data, setData] = useState([]); | 16 | const [data, setData] = useState([]); |
16 | const [loading, setLoading] = useState(true); | 17 | const [loading, setLoading] = useState(true); |
17 | let i = 0; | 18 | let i = 0; |
@@ -22,7 +23,7 @@ export default ({ subOrders, onClose }) => { | @@ -22,7 +23,7 @@ export default ({ subOrders, onClose }) => { | ||
22 | 23 | ||
23 | const getHistory = async () => { | 24 | const getHistory = async () => { |
24 | let res = await postServiceOrderQueryHistoryOrderRecord({ | 25 | let res = await postServiceOrderQueryHistoryOrderRecord({ |
25 | - data: { ids: subOrderIds }, | 26 | + data: { ids: subOrderIds, isDeleteQueryOrder: isCancelledOrder }, |
26 | }); | 27 | }); |
27 | setData(res.data); | 28 | setData(res.data); |
28 | setLoading(false); | 29 | setLoading(false); |
src/pages/Order/components/ProcureCheckModal.tsx
@@ -49,10 +49,14 @@ export default ({ setCheckVisible, data, subOrders, onClose }) => { | @@ -49,10 +49,14 @@ export default ({ setCheckVisible, data, subOrders, onClose }) => { | ||
49 | }} | 49 | }} |
50 | submitTimeout={2000} | 50 | submitTimeout={2000} |
51 | onFinish={async (values) => { | 51 | onFinish={async (values) => { |
52 | + let procureIsPrintAndSend = false; | ||
53 | + if (values.name === '采购自行发货') { | ||
54 | + procureIsPrintAndSend = true; | ||
55 | + } | ||
52 | return doCheck({ | 56 | return doCheck({ |
53 | ids: subOrderIds, | 57 | ids: subOrderIds, |
54 | supplier: values.name, | 58 | supplier: values.name, |
55 | - procureIsPrintAndSend: false, | 59 | + procureIsPrintAndSend: procureIsPrintAndSend, |
56 | }); | 60 | }); |
57 | }} | 61 | }} |
58 | onOpenChange={setCheckVisible} | 62 | onOpenChange={setCheckVisible} |
src/pages/Order/constant.ts
@@ -102,12 +102,23 @@ export const ORDER_STATUS_OPTIONS = { | @@ -102,12 +102,23 @@ export const ORDER_STATUS_OPTIONS = { | ||
102 | AUDITED: '已审核', | 102 | AUDITED: '已审核', |
103 | PROCURE_UN_PROCESS: '采购未审核', | 103 | PROCURE_UN_PROCESS: '采购未审核', |
104 | PROCURE_PROCESS: '采购已审核', | 104 | PROCURE_PROCESS: '采购已审核', |
105 | - SUPPLIER_WAIT_SHIP: '供应商-待发货', | ||
106 | - SUPPLIER_SHIPPED: '供应商-已发货', | 105 | + PROCURE_PROCESS_FOR_MINE: '采购待打印', |
106 | + PROCURE_WAIT_SHIP: '采购待发货', | ||
107 | + SUPPLIER_WAIT_SHIP: '供应商待发货', | ||
107 | WAIT_SHIP: '待发货', | 108 | WAIT_SHIP: '待发货', |
108 | SHIPPED: '已发货', | 109 | SHIPPED: '已发货', |
109 | CONFIRM_RECEIPT: '确认收货', | 110 | CONFIRM_RECEIPT: '确认收货', |
110 | AUDIT_FAILED: '审核失败', | 111 | AUDIT_FAILED: '审核失败', |
112 | + IN_AFTER_SALES: '售后中', | ||
113 | + AFTER_SALES_COMPLETION: '售后完成', | ||
114 | + NO_NEED_SEND: '无需发货', | ||
115 | +}; | ||
116 | + | ||
117 | +export const AFTE_SALES_PLAN_OPTIONS = { | ||
118 | + RETURNS_OR_REFUNDS: '退货/退款', | ||
119 | + EXCHANGE_GOODS: '换货', | ||
120 | + FREE_ORDER: '免单', | ||
121 | + DISCOUNT: '折扣', | ||
111 | }; | 122 | }; |
112 | 123 | ||
113 | export const FINANCIAL_STATUS_OPTIONS = { | 124 | export const FINANCIAL_STATUS_OPTIONS = { |
@@ -132,6 +143,11 @@ export const TAGS_COLOR = new Map<string, string>([ | @@ -132,6 +143,11 @@ export const TAGS_COLOR = new Map<string, string>([ | ||
132 | ['PROCURE_PROCESS', 'processing'], | 143 | ['PROCURE_PROCESS', 'processing'], |
133 | ['SUPPLIER_WAIT_SHIP', 'processing'], | 144 | ['SUPPLIER_WAIT_SHIP', 'processing'], |
134 | ['SUPPLIER_SHIPPED', 'processing'], | 145 | ['SUPPLIER_SHIPPED', 'processing'], |
146 | + ['IN_AFTER_SALES', 'red'], | ||
147 | + ['AFTER_SALES_COMPLETION', 'red'], | ||
148 | + ['PROCURE_PROCESS_FOR_MINE', 'processing'], | ||
149 | + ['PROCURE_WAIT_SHIP', 'processing'], | ||
150 | + ['NO_NEED_SEND', 'success'], | ||
135 | ]); | 151 | ]); |
136 | 152 | ||
137 | export const SALES_CODE_OPTIONS = [ | 153 | export const SALES_CODE_OPTIONS = [ |
@@ -196,6 +212,10 @@ export const HISTORY_OPT_TYPE = new Map<string, string>([ | @@ -196,6 +212,10 @@ export const HISTORY_OPT_TYPE = new Map<string, string>([ | ||
196 | ['PROCURE_CHECK_ORDER', '采购审核'], | 212 | ['PROCURE_CHECK_ORDER', '采购审核'], |
197 | ['SUPPLIER_PRINT', '供应商打印'], | 213 | ['SUPPLIER_PRINT', '供应商打印'], |
198 | ['EXTERNAL_PROCUREMENT', '仓库操作外部采购子订单'], | 214 | ['EXTERNAL_PROCUREMENT', '仓库操作外部采购子订单'], |
215 | + ['APPLY_AFTER_SALES', '申请售后子订单'], | ||
216 | + ['AFTER_SALES_COMPLETION', '完成售后子订单'], | ||
217 | + ['PROCURE_PRINT', '采购打印子订单'], | ||
218 | + ['PROCURE_SEND', '采购发货子订单'], | ||
199 | ]); | 219 | ]); |
200 | 220 | ||
201 | export const MAIN_ORDER_COLUMNS = [ | 221 | export const MAIN_ORDER_COLUMNS = [ |
@@ -208,7 +228,7 @@ export const MAIN_ORDER_COLUMNS = [ | @@ -208,7 +228,7 @@ export const MAIN_ORDER_COLUMNS = [ | ||
208 | { | 228 | { |
209 | title: '订单编号', | 229 | title: '订单编号', |
210 | dataIndex: 'id', | 230 | dataIndex: 'id', |
211 | - valueType: 'digit', | 231 | + valueType: 'text', |
212 | hideInTable: true, | 232 | hideInTable: true, |
213 | }, | 233 | }, |
214 | { | 234 | { |
@@ -254,6 +274,18 @@ export const MAIN_ORDER_COLUMNS = [ | @@ -254,6 +274,18 @@ export const MAIN_ORDER_COLUMNS = [ | ||
254 | hideInTable: true, | 274 | hideInTable: true, |
255 | }, | 275 | }, |
256 | { | 276 | { |
277 | + title: '主订单备注', | ||
278 | + dataIndex: 'mainNotes', | ||
279 | + valueType: 'text', | ||
280 | + hideInTable: true, | ||
281 | + }, | ||
282 | + { | ||
283 | + title: '子订单备注', | ||
284 | + dataIndex: 'subNotes', | ||
285 | + valueType: 'text', | ||
286 | + hideInTable: true, | ||
287 | + }, | ||
288 | + { | ||
257 | title: '商品参数', | 289 | title: '商品参数', |
258 | dataIndex: 'parameters', | 290 | dataIndex: 'parameters', |
259 | valueType: 'text', | 291 | valueType: 'text', |
src/pages/Order/index.tsx
1 | import ButtonConfirm from '@/components/ButtomConfirm'; | 1 | import ButtonConfirm from '@/components/ButtomConfirm'; |
2 | import { RESPONSE_CODE } from '@/constants/enum'; | 2 | import { RESPONSE_CODE } from '@/constants/enum'; |
3 | import { | 3 | import { |
4 | + postServiceOrderAfterSalesCompletion, | ||
5 | + postServiceOrderNoNeedSend, | ||
4 | postServiceOrderOrderCancel, | 6 | postServiceOrderOrderCancel, |
5 | postServiceOrderQueryServiceOrder, | 7 | postServiceOrderQueryServiceOrder, |
6 | } from '@/services'; | 8 | } from '@/services'; |
@@ -14,6 +16,7 @@ import { | @@ -14,6 +16,7 @@ import { | ||
14 | DownOutlined, | 16 | DownOutlined, |
15 | EditTwoTone, | 17 | EditTwoTone, |
16 | EllipsisOutlined, | 18 | EllipsisOutlined, |
19 | + QuestionCircleOutlined, | ||
17 | } from '@ant-design/icons'; | 20 | } from '@ant-design/icons'; |
18 | import { | 21 | import { |
19 | PageContainer, | 22 | PageContainer, |
@@ -37,6 +40,7 @@ import { | @@ -37,6 +40,7 @@ import { | ||
37 | import { cloneDeep } from 'lodash'; | 40 | import { cloneDeep } from 'lodash'; |
38 | import { Key, useRef, useState } from 'react'; | 41 | import { Key, useRef, useState } from 'react'; |
39 | import OrderPrintModal from '../OrderPrint/OrderPrintModal'; | 42 | import OrderPrintModal from '../OrderPrint/OrderPrintModal'; |
43 | +import AfterSalesDrawer from './components/AfterSalesDrawer'; | ||
40 | import AttachmentModal from './components/AttachmentModal'; | 44 | import AttachmentModal from './components/AttachmentModal'; |
41 | import CheckModal from './components/CheckModal'; | 45 | import CheckModal from './components/CheckModal'; |
42 | import ConfirmReceiptModal from './components/ConfirmReceiptModal'; | 46 | import ConfirmReceiptModal from './components/ConfirmReceiptModal'; |
@@ -50,6 +54,7 @@ import OrderNotesEditModal from './components/OrderNotesEditModal'; | @@ -50,6 +54,7 @@ import OrderNotesEditModal from './components/OrderNotesEditModal'; | ||
50 | import ProcureCheckModal from './components/ProcureCheckModal'; | 54 | import ProcureCheckModal from './components/ProcureCheckModal'; |
51 | import SubOrderComfirmReceiptImagesModal from './components/SubOrderComfirmReceiptImagesModal'; | 55 | import SubOrderComfirmReceiptImagesModal from './components/SubOrderComfirmReceiptImagesModal'; |
52 | import { | 56 | import { |
57 | + AFTE_SALES_PLAN_OPTIONS, | ||
53 | CHECK_TYPE, | 58 | CHECK_TYPE, |
54 | LOGISTICS_STATUS_OPTIONS, | 59 | LOGISTICS_STATUS_OPTIONS, |
55 | MAIN_ORDER_COLUMNS, | 60 | MAIN_ORDER_COLUMNS, |
@@ -76,6 +81,8 @@ const OrderPage = () => { | @@ -76,6 +81,8 @@ const OrderPage = () => { | ||
76 | const [attachmentModalVisible, setAttachmentModalVisible] = | 81 | const [attachmentModalVisible, setAttachmentModalVisible] = |
77 | useState<boolean>(false); | 82 | useState<boolean>(false); |
78 | const [financialVisible, setFinancialVisible] = useState<boolean>(false); | 83 | const [financialVisible, setFinancialVisible] = useState<boolean>(false); |
84 | + const [afterSalesDrawerVisible, setAfterSalesDrawerVisible] = | ||
85 | + useState<boolean>(false); | ||
79 | const [historyModalVisible, setHistoryModalVisible] = | 86 | const [historyModalVisible, setHistoryModalVisible] = |
80 | useState<boolean>(false); | 87 | useState<boolean>(false); |
81 | const [isRePrintOrder, setIsRePrintOrder] = useState<boolean>(false); | 88 | const [isRePrintOrder, setIsRePrintOrder] = useState<boolean>(false); |
@@ -104,7 +111,9 @@ const OrderPage = () => { | @@ -104,7 +111,9 @@ const OrderPage = () => { | ||
104 | const [pageSize, setPageSize] = useState(10); | 111 | const [pageSize, setPageSize] = useState(10); |
105 | const [currentPage, setCurrentPage] = useState(1); | 112 | const [currentPage, setCurrentPage] = useState(1); |
106 | const [orderCheckType, setOrderCheckType] = useState(''); | 113 | const [orderCheckType, setOrderCheckType] = useState(''); |
114 | + const [onlyShowCancelOrder, setOnlyShowCancelOrder] = useState(false); | ||
107 | const mainTableRef = useRef(); | 115 | const mainTableRef = useRef(); |
116 | + let [searchParams, setSearchParam] = useState(Object); //表格的查询条件存储 | ||
108 | const [messageApi, contextHolder] = message.useMessage(); | 117 | const [messageApi, contextHolder] = message.useMessage(); |
109 | 118 | ||
110 | // const openCheckNotes = (checkNotes: string) => { | 119 | // const openCheckNotes = (checkNotes: string) => { |
@@ -139,6 +148,11 @@ const OrderPage = () => { | @@ -139,6 +148,11 @@ const OrderPage = () => { | ||
139 | setSelectedRowKeys([]); | 148 | setSelectedRowKeys([]); |
140 | }; | 149 | }; |
141 | 150 | ||
151 | + function changeCancelOrderShow(e: any) { | ||
152 | + setOnlyShowCancelOrder(e.target.checked); | ||
153 | + refreshTable(); | ||
154 | + } | ||
155 | + | ||
142 | // const resize = () => { | 156 | // const resize = () => { |
143 | // // 计算元素底部到视口顶部的距离 | 157 | // // 计算元素底部到视口顶部的距离 |
144 | // let bottomDistance = document | 158 | // let bottomDistance = document |
@@ -164,6 +178,18 @@ const OrderPage = () => { | @@ -164,6 +178,18 @@ const OrderPage = () => { | ||
164 | // window.addEventListener('resize', resize); | 178 | // window.addEventListener('resize', resize); |
165 | // }); | 179 | // }); |
166 | 180 | ||
181 | + const MyToolTip = ({ title, content }) => { | ||
182 | + return ( | ||
183 | + <Tooltip | ||
184 | + color="#FFFFFF" | ||
185 | + placement="bottom" | ||
186 | + title={<div className="px-5 py-4 text-black">{title}</div>} | ||
187 | + > | ||
188 | + {content} | ||
189 | + </Tooltip> | ||
190 | + ); | ||
191 | + }; | ||
192 | + | ||
167 | const onCheckboxChange = (record: never) => { | 193 | const onCheckboxChange = (record: never) => { |
168 | let newSelectedItems = []; | 194 | let newSelectedItems = []; |
169 | if (selectedItems.includes(record.id)) { | 195 | if (selectedItems.includes(record.id)) { |
@@ -222,20 +248,87 @@ const OrderPage = () => { | @@ -222,20 +248,87 @@ const OrderPage = () => { | ||
222 | }; | 248 | }; |
223 | //子订单内容渲染 | 249 | //子订单内容渲染 |
224 | const SubOderRander = ({ record, optRecord }) => { | 250 | const SubOderRander = ({ record, optRecord }) => { |
251 | + /** | ||
252 | + * 获取订单状态标签 | ||
253 | + * @param optRecord | ||
254 | + */ | ||
255 | + function getOrderStatusTag(optRecord: any): import('react').ReactNode { | ||
256 | + const orderStatus = optRecord.orderStatus; | ||
257 | + if (orderStatus === 'AUDIT_FAILED') { | ||
258 | + return ( | ||
259 | + <MyToolTip | ||
260 | + title={optRecord.checkNotes} | ||
261 | + content={ | ||
262 | + <> | ||
263 | + <Tag | ||
264 | + color={TAGS_COLOR.get(optRecord.orderStatus)} | ||
265 | + style={{ marginRight: '4px' }} | ||
266 | + > | ||
267 | + {enumValueToLabel( | ||
268 | + optRecord.orderStatus, | ||
269 | + ORDER_STATUS_OPTIONS, | ||
270 | + )} | ||
271 | + </Tag> | ||
272 | + <QuestionCircleOutlined style={{ color: '#C1C1C1' }} /> | ||
273 | + </> | ||
274 | + } | ||
275 | + /> | ||
276 | + ); | ||
277 | + } | ||
278 | + | ||
279 | + if ( | ||
280 | + orderStatus === 'AFTER_SALES_COMPLETION' || | ||
281 | + orderStatus === 'IN_AFTER_SALES' | ||
282 | + ) { | ||
283 | + return ( | ||
284 | + <MyToolTip | ||
285 | + title={ | ||
286 | + enumValueToLabel( | ||
287 | + optRecord.afterSalesPlan, | ||
288 | + AFTE_SALES_PLAN_OPTIONS, | ||
289 | + ) + | ||
290 | + ' ' + | ||
291 | + optRecord.afterSalesNotes | ||
292 | + } | ||
293 | + content={ | ||
294 | + <> | ||
295 | + <Tag | ||
296 | + color={TAGS_COLOR.get(optRecord.orderStatus)} | ||
297 | + style={{ marginRight: '4px' }} | ||
298 | + > | ||
299 | + {enumValueToLabel( | ||
300 | + optRecord.orderStatus, | ||
301 | + ORDER_STATUS_OPTIONS, | ||
302 | + )} | ||
303 | + </Tag> | ||
304 | + <QuestionCircleOutlined style={{ color: '#C1C1C1' }} /> | ||
305 | + </> | ||
306 | + } | ||
307 | + /> | ||
308 | + ); | ||
309 | + } | ||
310 | + | ||
311 | + return ( | ||
312 | + <Tag color={TAGS_COLOR.get(optRecord.orderStatus)}> | ||
313 | + {enumValueToLabel(optRecord.orderStatus, ORDER_STATUS_OPTIONS)} | ||
314 | + </Tag> | ||
315 | + ); | ||
316 | + } | ||
317 | + | ||
225 | return ( | 318 | return ( |
226 | <Flex className="w-full border-b-indigo-500"> | 319 | <Flex className="w-full border-b-indigo-500"> |
227 | <Flex vertical className="w-[31%]" gap="small"> | 320 | <Flex vertical className="w-[31%]" gap="small"> |
228 | {/* 商品名称 */} | 321 | {/* 商品名称 */} |
229 | <div | 322 | <div |
230 | - className="whitespace-no-wrap overflow-hidden overflow-ellipsis" | 323 | + className="overflow-hidden whitespace-no-wrap overflow-ellipsis" |
231 | title={optRecord.productName} | 324 | title={optRecord.productName} |
232 | > | 325 | > |
233 | - <span className="text-black font-medium "> | 326 | + <span className="font-medium text-black "> |
234 | {optRecord.productName} | 327 | {optRecord.productName} |
235 | </span> | 328 | </span> |
236 | </div> | 329 | </div> |
237 | <div | 330 | <div |
238 | - className="whitespace-no-wrap overflow-hidden overflow-ellipsis" | 331 | + className="overflow-hidden whitespace-no-wrap overflow-ellipsis" |
239 | title={optRecord.parameters} | 332 | title={optRecord.parameters} |
240 | > | 333 | > |
241 | <span className="text-[#8C8C8C]">参数:{optRecord.parameters}</span> | 334 | <span className="text-[#8C8C8C]">参数:{optRecord.parameters}</span> |
@@ -256,24 +349,40 @@ const OrderPage = () => { | @@ -256,24 +349,40 @@ const OrderPage = () => { | ||
256 | }} | 349 | }} |
257 | /> | 350 | /> |
258 | </Flex> | 351 | </Flex> |
352 | + | ||
353 | + <Flex title={optRecord.notes}> | ||
354 | + <div className="max-w-[90%] whitespace-no-wrap overflow-hidden overflow-ellipsis"> | ||
355 | + <span className="text-[#8C8C8C]"> | ||
356 | + 开票备注:请将2312210003,2312210002,2312210001订单合并开票 | ||
357 | + </span> | ||
358 | + </div> | ||
359 | + {/* 编辑备注按钮 */} | ||
360 | + <EditTwoTone | ||
361 | + onClick={() => { | ||
362 | + setNotesEditVisible(true); | ||
363 | + setOrderRow(optRecord); | ||
364 | + setIsMainOrder(false); | ||
365 | + }} | ||
366 | + /> | ||
367 | + </Flex> | ||
259 | </Flex> | 368 | </Flex> |
260 | <Flex className="w-[16%]" vertical gap="small"> | 369 | <Flex className="w-[16%]" vertical gap="small"> |
261 | <div | 370 | <div |
262 | - className="whitespace-no-wrap overflow-hidden overflow-ellipsis" | 371 | + className="overflow-hidden whitespace-no-wrap overflow-ellipsis" |
263 | title={optRecord.productPrice} | 372 | title={optRecord.productPrice} |
264 | > | 373 | > |
265 | <span className="text-[#8C8C8C]">单价:</span> | 374 | <span className="text-[#8C8C8C]">单价:</span> |
266 | <span className="text-slate-700">¥{optRecord.productPrice}</span> | 375 | <span className="text-slate-700">¥{optRecord.productPrice}</span> |
267 | </div> | 376 | </div> |
268 | <div | 377 | <div |
269 | - className="whitespace-no-wrap overflow-hidden overflow-ellipsis" | 378 | + className="overflow-hidden whitespace-no-wrap overflow-ellipsis" |
270 | title={optRecord.quantity} | 379 | title={optRecord.quantity} |
271 | > | 380 | > |
272 | <span className="text-[#8C8C8C]">数量:</span> | 381 | <span className="text-[#8C8C8C]">数量:</span> |
273 | <span className="text-slate-700">x{optRecord.quantity}</span> | 382 | <span className="text-slate-700">x{optRecord.quantity}</span> |
274 | </div> | 383 | </div> |
275 | <div | 384 | <div |
276 | - className="whitespace-no-wrap overflow-hidden overflow-ellipsis" | 385 | + className="overflow-hidden whitespace-no-wrap overflow-ellipsis" |
277 | title={optRecord.subOrderPayment} | 386 | title={optRecord.subOrderPayment} |
278 | > | 387 | > |
279 | <span className="text-[#8C8C8C]">合计:</span> | 388 | <span className="text-[#8C8C8C]">合计:</span> |
@@ -284,7 +393,7 @@ const OrderPage = () => { | @@ -284,7 +393,7 @@ const OrderPage = () => { | ||
284 | </Flex> | 393 | </Flex> |
285 | <Flex className="w-[10%]" vertical gap="small"> | 394 | <Flex className="w-[10%]" vertical gap="small"> |
286 | {/* 支付方式 */} | 395 | {/* 支付方式 */} |
287 | - <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> | 396 | + <div className="overflow-hidden whitespace-no-wrap overflow-ellipsis"> |
288 | <span className="text-slate-700"> | 397 | <span className="text-slate-700"> |
289 | {enumValueToLabel( | 398 | {enumValueToLabel( |
290 | optRecord.paymentMethod, | 399 | optRecord.paymentMethod, |
@@ -293,7 +402,7 @@ const OrderPage = () => { | @@ -293,7 +402,7 @@ const OrderPage = () => { | ||
293 | </span> | 402 | </span> |
294 | </div> | 403 | </div> |
295 | {/* 支付渠道 */} | 404 | {/* 支付渠道 */} |
296 | - <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> | 405 | + <div className="overflow-hidden whitespace-no-wrap overflow-ellipsis"> |
297 | <span className="text-slate-700"> | 406 | <span className="text-slate-700"> |
298 | {enumValueToLabel( | 407 | {enumValueToLabel( |
299 | optRecord.paymentChannel, | 408 | optRecord.paymentChannel, |
@@ -305,7 +414,7 @@ const OrderPage = () => { | @@ -305,7 +414,7 @@ const OrderPage = () => { | ||
305 | <Flex className="w-[15%]" vertical gap="small"> | 414 | <Flex className="w-[15%]" vertical gap="small"> |
306 | {/* 所属部门 */} | 415 | {/* 所属部门 */} |
307 | <div | 416 | <div |
308 | - className="whitespace-no-wrap overflow-hidden overflow-ellipsis" | 417 | + className="overflow-hidden whitespace-no-wrap overflow-ellipsis" |
309 | title={enumValueToLabel( | 418 | title={enumValueToLabel( |
310 | optRecord.productBelongBusiness, | 419 | optRecord.productBelongBusiness, |
311 | PRODUCT_BELONG_DEPARTMENT_OPTIONS, | 420 | PRODUCT_BELONG_DEPARTMENT_OPTIONS, |
@@ -320,16 +429,23 @@ const OrderPage = () => { | @@ -320,16 +429,23 @@ const OrderPage = () => { | ||
320 | </div> | 429 | </div> |
321 | 430 | ||
322 | {/* 开票类型 */} | 431 | {/* 开票类型 */} |
323 | - <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> | 432 | + <div className="overflow-hidden whitespace-no-wrap overflow-ellipsis"> |
324 | <span className="text-slate-700"> | 433 | <span className="text-slate-700"> |
325 | {getInvoicingType(optRecord)} | 434 | {getInvoicingType(optRecord)} |
326 | </span> | 435 | </span> |
327 | </div> | 436 | </div> |
437 | + | ||
438 | + {/* 开票状态 */} | ||
439 | + {/* <div className="overflow-hidden whitespace-no-wrap overflow-ellipsis"> | ||
440 | + <span className="text-slate-700"> | ||
441 | + 部分开票 | ||
442 | + </span> | ||
443 | + </div> */} | ||
328 | </Flex> | 444 | </Flex> |
329 | 445 | ||
330 | <Flex className="w-[10%]" vertical gap="small"> | 446 | <Flex className="w-[10%]" vertical gap="small"> |
331 | {/* 开票状态 */} | 447 | {/* 开票状态 */} |
332 | - <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> | 448 | + <div className="overflow-hidden whitespace-no-wrap overflow-ellipsis"> |
333 | <Tag | 449 | <Tag |
334 | color={ | 450 | color={ |
335 | optRecord.invoicingTime === null || | 451 | optRecord.invoicingTime === null || |
@@ -342,43 +458,40 @@ const OrderPage = () => { | @@ -342,43 +458,40 @@ const OrderPage = () => { | ||
342 | </Tag> | 458 | </Tag> |
343 | </div> | 459 | </div> |
344 | {/* 订单状态 */} | 460 | {/* 订单状态 */} |
345 | - <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> | ||
346 | - <Tag color={TAGS_COLOR.get(optRecord.orderStatus)}> | ||
347 | - {enumValueToLabel(optRecord.orderStatus, ORDER_STATUS_OPTIONS)} | ||
348 | - </Tag> | 461 | + <div className="overflow-hidden whitespace-no-wrap overflow-ellipsis"> |
462 | + {getOrderStatusTag(optRecord)} | ||
349 | </div> | 463 | </div> |
350 | 464 | ||
351 | {/* 物流信息 */} | 465 | {/* 物流信息 */} |
352 | - <div className="whitespace-no-wrap overflow-hidden overflow-ellipsis"> | 466 | + <div className="overflow-hidden whitespace-no-wrap overflow-ellipsis"> |
353 | {optRecord.orderStatus === 'CONFIRM_RECEIPT' || | 467 | {optRecord.orderStatus === 'CONFIRM_RECEIPT' || |
468 | + optRecord.orderStatus === 'AFTER_SALES_COMPLETION' || | ||
469 | + optRecord.orderStatus === 'IN_AFTER_SALES' || | ||
354 | optRecord.orderStatus === 'SHIPPED' ? ( | 470 | optRecord.orderStatus === 'SHIPPED' ? ( |
355 | - <Tooltip | ||
356 | - color="#FFFFFF" | ||
357 | - placement="bottom" | 471 | + <MyToolTip |
358 | title={ | 472 | title={ |
359 | - <div className="text-black px-5 py-4"> | ||
360 | - {optRecord.serialNumber === undefined | ||
361 | - ? '暂无物流信息' | ||
362 | - : enumValueToLabel( | ||
363 | - optRecord.logisticsMethod, | ||
364 | - LOGISTICS_STATUS_OPTIONS, | ||
365 | - ) + | ||
366 | - ' ' + | ||
367 | - optRecord.serialNumber} | ||
368 | - </div> | 473 | + optRecord.serialNumber === undefined |
474 | + ? '暂无物流信息' | ||
475 | + : enumValueToLabel( | ||
476 | + optRecord.logisticsMethod, | ||
477 | + LOGISTICS_STATUS_OPTIONS, | ||
478 | + ) + | ||
479 | + ' ' + | ||
480 | + optRecord.serialNumber | ||
369 | } | 481 | } |
370 | - > | ||
371 | - <Button type="link" size="small" style={{ padding: 0 }}> | ||
372 | - 物流信息 | ||
373 | - </Button> | ||
374 | - </Tooltip> | 482 | + content={ |
483 | + <Button type="link" size="small" style={{ padding: 0 }}> | ||
484 | + 物流信息 | ||
485 | + </Button> | ||
486 | + } | ||
487 | + /> | ||
375 | ) : ( | 488 | ) : ( |
376 | '' | 489 | '' |
377 | )} | 490 | )} |
378 | </div> | 491 | </div> |
379 | </Flex> | 492 | </Flex> |
380 | <Flex className="w-[18%]" wrap="wrap" gap="small"> | 493 | <Flex className="w-[18%]" wrap="wrap" gap="small"> |
381 | - {optRecord.subPath.includes('sendProduct') ? ( | 494 | + {optRecord.subPath?.includes('sendProduct') ? ( |
382 | <Button | 495 | <Button |
383 | className="p-0" | 496 | className="p-0" |
384 | type="link" | 497 | type="link" |
@@ -390,13 +503,13 @@ const OrderPage = () => { | @@ -390,13 +503,13 @@ const OrderPage = () => { | ||
390 | setOrderCheckType(CHECK_TYPE.NORMAL); | 503 | setOrderCheckType(CHECK_TYPE.NORMAL); |
391 | }} | 504 | }} |
392 | > | 505 | > |
393 | - 发货 | 506 | + 仓库发货 |
394 | </Button> | 507 | </Button> |
395 | ) : ( | 508 | ) : ( |
396 | '' | 509 | '' |
397 | )} | 510 | )} |
398 | 511 | ||
399 | - {optRecord.subPath.includes('supplierSendOrder') ? ( | 512 | + {optRecord.subPath?.includes('supplierSendOrder') ? ( |
400 | <Button | 513 | <Button |
401 | className="p-0" | 514 | className="p-0" |
402 | type="link" | 515 | type="link" |
@@ -414,7 +527,25 @@ const OrderPage = () => { | @@ -414,7 +527,25 @@ const OrderPage = () => { | ||
414 | '' | 527 | '' |
415 | )} | 528 | )} |
416 | 529 | ||
417 | - {optRecord.subPath.includes('queryAnnex') && | 530 | + {optRecord.subPath?.includes('procureSend') ? ( |
531 | + <Button | ||
532 | + className="p-0" | ||
533 | + type="link" | ||
534 | + onClick={() => { | ||
535 | + optRecord.mainOrderId = record.id; | ||
536 | + setSelectedRows([cloneDeep(optRecord)]); //克隆一份数据,避免后续修改污染 | ||
537 | + setDeliverVisible(true); | ||
538 | + setIsSendProduct(true); | ||
539 | + setOrderCheckType(CHECK_TYPE.PROCURE); | ||
540 | + }} | ||
541 | + > | ||
542 | + 采购发货 | ||
543 | + </Button> | ||
544 | + ) : ( | ||
545 | + '' | ||
546 | + )} | ||
547 | + | ||
548 | + {optRecord.subPath?.includes('queryAnnex') && | ||
418 | optRecord.listAnnex?.length > 0 ? ( | 549 | optRecord.listAnnex?.length > 0 ? ( |
419 | <Button | 550 | <Button |
420 | className="p-0" | 551 | className="p-0" |
@@ -431,7 +562,7 @@ const OrderPage = () => { | @@ -431,7 +562,7 @@ const OrderPage = () => { | ||
431 | '' | 562 | '' |
432 | )} | 563 | )} |
433 | 564 | ||
434 | - {optRecord.subPath.includes('modifySendInformation') ? ( | 565 | + {optRecord.subPath?.includes('modifySendInformation') ? ( |
435 | <Button | 566 | <Button |
436 | className="p-0" | 567 | className="p-0" |
437 | type="link" | 568 | type="link" |
@@ -448,7 +579,7 @@ const OrderPage = () => { | @@ -448,7 +579,7 @@ const OrderPage = () => { | ||
448 | '' | 579 | '' |
449 | )} | 580 | )} |
450 | 581 | ||
451 | - {optRecord.subPath.includes('printOrder') ? ( | 582 | + {optRecord.subPath?.includes('printOrder') ? ( |
452 | <Button | 583 | <Button |
453 | className="p-0" | 584 | className="p-0" |
454 | type="link" | 585 | type="link" |
@@ -459,13 +590,13 @@ const OrderPage = () => { | @@ -459,13 +590,13 @@ const OrderPage = () => { | ||
459 | setOrderCheckType(CHECK_TYPE.NORMAL); | 590 | setOrderCheckType(CHECK_TYPE.NORMAL); |
460 | }} | 591 | }} |
461 | > | 592 | > |
462 | - 打印 | 593 | + 仓库打印 |
463 | </Button> | 594 | </Button> |
464 | ) : ( | 595 | ) : ( |
465 | '' | 596 | '' |
466 | )} | 597 | )} |
467 | 598 | ||
468 | - {optRecord.subPath.includes('supplierPrint') ? ( | 599 | + {optRecord.subPath?.includes('supplierPrint') ? ( |
469 | <Button | 600 | <Button |
470 | className="p-0" | 601 | className="p-0" |
471 | type="link" | 602 | type="link" |
@@ -476,13 +607,30 @@ const OrderPage = () => { | @@ -476,13 +607,30 @@ const OrderPage = () => { | ||
476 | setOrderCheckType(CHECK_TYPE.SUPPLIER); | 607 | setOrderCheckType(CHECK_TYPE.SUPPLIER); |
477 | }} | 608 | }} |
478 | > | 609 | > |
479 | - 打印 | 610 | + 供应商打印 |
611 | + </Button> | ||
612 | + ) : ( | ||
613 | + '' | ||
614 | + )} | ||
615 | + | ||
616 | + {optRecord.subPath?.includes('procurePrint') ? ( | ||
617 | + <Button | ||
618 | + className="p-0" | ||
619 | + type="link" | ||
620 | + onClick={async () => { | ||
621 | + setOrderPrintVisible(true); | ||
622 | + setSelectedRows([optRecord]); | ||
623 | + setOrderRow(record); | ||
624 | + setOrderCheckType(CHECK_TYPE.PROCURE); | ||
625 | + }} | ||
626 | + > | ||
627 | + 采购打印 | ||
480 | </Button> | 628 | </Button> |
481 | ) : ( | 629 | ) : ( |
482 | '' | 630 | '' |
483 | )} | 631 | )} |
484 | 632 | ||
485 | - {optRecord.subPath.includes('editOrder') ? ( | 633 | + {optRecord.subPath?.includes('editOrder') ? ( |
486 | <Button | 634 | <Button |
487 | className="p-0" | 635 | className="p-0" |
488 | type="link" | 636 | type="link" |
@@ -498,7 +646,7 @@ const OrderPage = () => { | @@ -498,7 +646,7 @@ const OrderPage = () => { | ||
498 | ) : ( | 646 | ) : ( |
499 | '' | 647 | '' |
500 | )} | 648 | )} |
501 | - {optRecord.subPath.includes('invoicing') ? ( | 649 | + {optRecord.subPath?.includes('invoicing') ? ( |
502 | <Button | 650 | <Button |
503 | className="p-0" | 651 | className="p-0" |
504 | type="link" | 652 | type="link" |
@@ -515,7 +663,7 @@ const OrderPage = () => { | @@ -515,7 +663,7 @@ const OrderPage = () => { | ||
515 | ) : ( | 663 | ) : ( |
516 | '' | 664 | '' |
517 | )} | 665 | )} |
518 | - {optRecord.subPath.includes('checkOrder') ? ( | 666 | + {optRecord.subPath?.includes('checkOrder') ? ( |
519 | <Button | 667 | <Button |
520 | className="p-0" | 668 | className="p-0" |
521 | type="link" | 669 | type="link" |
@@ -532,7 +680,7 @@ const OrderPage = () => { | @@ -532,7 +680,7 @@ const OrderPage = () => { | ||
532 | '' | 680 | '' |
533 | )} | 681 | )} |
534 | 682 | ||
535 | - {optRecord.subPath.includes('financeCheckOrder') ? ( | 683 | + {optRecord.subPath?.includes('financeCheckOrder') ? ( |
536 | <Button | 684 | <Button |
537 | className="p-0" | 685 | className="p-0" |
538 | type="link" | 686 | type="link" |
@@ -549,7 +697,7 @@ const OrderPage = () => { | @@ -549,7 +697,7 @@ const OrderPage = () => { | ||
549 | '' | 697 | '' |
550 | )} | 698 | )} |
551 | 699 | ||
552 | - {optRecord.subPath.includes('procureCheckOrder') ? ( | 700 | + {optRecord.subPath?.includes('procureCheckOrder') ? ( |
553 | <Button | 701 | <Button |
554 | className="p-0" | 702 | className="p-0" |
555 | type="link" | 703 | type="link" |
@@ -566,7 +714,7 @@ const OrderPage = () => { | @@ -566,7 +714,7 @@ const OrderPage = () => { | ||
566 | '' | 714 | '' |
567 | )} | 715 | )} |
568 | 716 | ||
569 | - {optRecord.subPath.includes('rePrintOrder') ? ( | 717 | + {optRecord.subPath?.includes('rePrintOrder') ? ( |
570 | <Button | 718 | <Button |
571 | className="p-0" | 719 | className="p-0" |
572 | type="link" | 720 | type="link" |
@@ -583,7 +731,7 @@ const OrderPage = () => { | @@ -583,7 +731,7 @@ const OrderPage = () => { | ||
583 | '' | 731 | '' |
584 | )} | 732 | )} |
585 | 733 | ||
586 | - {optRecord.subPath.includes('confirmReceipt') ? ( | 734 | + {optRecord.subPath?.includes('confirmReceipt') ? ( |
587 | <Button | 735 | <Button |
588 | className="p-0" | 736 | className="p-0" |
589 | type="link" | 737 | type="link" |
@@ -597,7 +745,64 @@ const OrderPage = () => { | @@ -597,7 +745,64 @@ const OrderPage = () => { | ||
597 | ) : ( | 745 | ) : ( |
598 | '' | 746 | '' |
599 | )} | 747 | )} |
600 | - {optRecord.subPath.includes('viewImages') ? ( | 748 | + |
749 | + {optRecord.subPath?.includes('applyAfterSales') ? ( | ||
750 | + <Button | ||
751 | + className="p-0" | ||
752 | + type="link" | ||
753 | + onClick={() => { | ||
754 | + setAfterSalesDrawerVisible(true); | ||
755 | + setSelectedRows([optRecord]); | ||
756 | + setOrderRow(record); | ||
757 | + }} | ||
758 | + > | ||
759 | + 申请售后 | ||
760 | + </Button> | ||
761 | + ) : ( | ||
762 | + '' | ||
763 | + )} | ||
764 | + | ||
765 | + {optRecord.subPath?.includes('afterSalesCompletion') ? ( | ||
766 | + <ButtonConfirm | ||
767 | + className="p-0" | ||
768 | + title="是否完成售后?" | ||
769 | + text="完成售后" | ||
770 | + onConfirm={async () => { | ||
771 | + let res = await postServiceOrderAfterSalesCompletion({ | ||
772 | + data: { ids: [optRecord.id] }, | ||
773 | + }); | ||
774 | + if (res.result === RESPONSE_CODE.SUCCESS) { | ||
775 | + message.success(res.message); | ||
776 | + refreshTable(); | ||
777 | + return true; | ||
778 | + } | ||
779 | + }} | ||
780 | + /> | ||
781 | + ) : ( | ||
782 | + '' | ||
783 | + )} | ||
784 | + | ||
785 | + {optRecord.subPath?.includes('noNeedSend') ? ( | ||
786 | + <ButtonConfirm | ||
787 | + className="p-0" | ||
788 | + title="此订单是否无需发货?" | ||
789 | + text="无需发货" | ||
790 | + onConfirm={async () => { | ||
791 | + let res = await postServiceOrderNoNeedSend({ | ||
792 | + data: { ids: [optRecord.id] }, | ||
793 | + }); | ||
794 | + if (res.result === RESPONSE_CODE.SUCCESS) { | ||
795 | + message.success(res.message); | ||
796 | + refreshTable(); | ||
797 | + return true; | ||
798 | + } | ||
799 | + }} | ||
800 | + /> | ||
801 | + ) : ( | ||
802 | + '' | ||
803 | + )} | ||
804 | + | ||
805 | + {optRecord.subPath?.includes('viewImages') ? ( | ||
601 | <Button | 806 | <Button |
602 | className="p-0" | 807 | className="p-0" |
603 | type="link" | 808 | type="link" |
@@ -612,7 +817,7 @@ const OrderPage = () => { | @@ -612,7 +817,7 @@ const OrderPage = () => { | ||
612 | '' | 817 | '' |
613 | )} | 818 | )} |
614 | 819 | ||
615 | - {optRecord.subPath.includes('orderCancel') ? ( | 820 | + {optRecord.subPath?.includes('orderCancel') ? ( |
616 | <ButtonConfirm | 821 | <ButtonConfirm |
617 | className="p-0" | 822 | className="p-0" |
618 | title="确认作废?" | 823 | title="确认作废?" |
@@ -641,7 +846,7 @@ const OrderPage = () => { | @@ -641,7 +846,7 @@ const OrderPage = () => { | ||
641 | return ( | 846 | return ( |
642 | <ProTable | 847 | <ProTable |
643 | id="sub-table" | 848 | id="sub-table" |
644 | - className=" w-full" | 849 | + className="w-full " |
645 | showHeader={false} | 850 | showHeader={false} |
646 | columns={[ | 851 | columns={[ |
647 | { | 852 | { |
@@ -686,7 +891,7 @@ const OrderPage = () => { | @@ -686,7 +891,7 @@ const OrderPage = () => { | ||
686 | <Flex vertical={true}> | 891 | <Flex vertical={true}> |
687 | {/* 编号、时间、销售信息 */} | 892 | {/* 编号、时间、销售信息 */} |
688 | <Flex | 893 | <Flex |
689 | - className="px-4 py-4 bg-white bg-white rounded-t-lg" | 894 | + className="px-4 py-4 bg-white rounded-t-lg" |
690 | justify="space-between" | 895 | justify="space-between" |
691 | > | 896 | > |
692 | <Flex wrap="wrap" gap="middle" vertical> | 897 | <Flex wrap="wrap" gap="middle" vertical> |
@@ -742,7 +947,7 @@ const OrderPage = () => { | @@ -742,7 +947,7 @@ const OrderPage = () => { | ||
742 | </Flex> | 947 | </Flex> |
743 | <Flex className="pl-6" align="center"> | 948 | <Flex className="pl-6" align="center"> |
744 | <div title={record.notes}> | 949 | <div title={record.notes}> |
745 | - <div className="max-w-md whitespace-no-wrap overflow-hidden overflow-ellipsis"> | 950 | + <div className="max-w-md overflow-hidden whitespace-no-wrap overflow-ellipsis"> |
746 | <span className="text-[#8C8C8C]">备注:</span> | 951 | <span className="text-[#8C8C8C]">备注:</span> |
747 | <span className="ml-2"> | 952 | <span className="ml-2"> |
748 | {record.notes === undefined ? '暂无备注' : record.notes} | 953 | {record.notes === undefined ? '暂无备注' : record.notes} |
@@ -808,7 +1013,7 @@ const OrderPage = () => { | @@ -808,7 +1013,7 @@ const OrderPage = () => { | ||
808 | <Flex justify="flex-end"> | 1013 | <Flex justify="flex-end"> |
809 | <Space.Compact direction="vertical" align="end"> | 1014 | <Space.Compact direction="vertical" align="end"> |
810 | <Space> | 1015 | <Space> |
811 | - {record.mainPath.includes('sendProduct') ? ( | 1016 | + {record.mainPath?.includes('sendProduct') ? ( |
812 | <Button | 1017 | <Button |
813 | className="p-0" | 1018 | className="p-0" |
814 | type="link" | 1019 | type="link" |
@@ -822,14 +1027,14 @@ const OrderPage = () => { | @@ -822,14 +1027,14 @@ const OrderPage = () => { | ||
822 | setOrderCheckType(CHECK_TYPE.NORMAL); | 1027 | setOrderCheckType(CHECK_TYPE.NORMAL); |
823 | }} | 1028 | }} |
824 | > | 1029 | > |
825 | - 发货 | 1030 | + 仓库发货 |
826 | </Button> | 1031 | </Button> |
827 | ) : ( | 1032 | ) : ( |
828 | '' | 1033 | '' |
829 | )} | 1034 | )} |
830 | 1035 | ||
831 | {/* 供应商发货 */} | 1036 | {/* 供应商发货 */} |
832 | - {record.mainPath.includes('supplierSendOrder') ? ( | 1037 | + {record.mainPath?.includes('supplierSendOrder') ? ( |
833 | <Button | 1038 | <Button |
834 | className="p-0" | 1039 | className="p-0" |
835 | type="link" | 1040 | type="link" |
@@ -848,7 +1053,28 @@ const OrderPage = () => { | @@ -848,7 +1053,28 @@ const OrderPage = () => { | ||
848 | ) : ( | 1053 | ) : ( |
849 | '' | 1054 | '' |
850 | )} | 1055 | )} |
851 | - {record.mainPath.includes('printOrder') ? ( | 1056 | + |
1057 | + {record.mainPath?.includes('procureSend') ? ( | ||
1058 | + <Button | ||
1059 | + className="p-0" | ||
1060 | + type="link" | ||
1061 | + onClick={() => { | ||
1062 | + if (!selectedRowObj[record.id]?.length) { | ||
1063 | + return message.error('请选择选择子订单'); | ||
1064 | + } | ||
1065 | + setSelectedRows(selectedRowObj[record.id]); | ||
1066 | + setDeliverVisible(true); | ||
1067 | + setIsSendProduct(true); | ||
1068 | + setOrderCheckType(CHECK_TYPE.PROCURE); | ||
1069 | + }} | ||
1070 | + > | ||
1071 | + 采购发货 | ||
1072 | + </Button> | ||
1073 | + ) : ( | ||
1074 | + '' | ||
1075 | + )} | ||
1076 | + | ||
1077 | + {record.mainPath?.includes('printOrder') ? ( | ||
852 | <Button | 1078 | <Button |
853 | className="p-0" | 1079 | className="p-0" |
854 | type="link" | 1080 | type="link" |
@@ -862,13 +1088,13 @@ const OrderPage = () => { | @@ -862,13 +1088,13 @@ const OrderPage = () => { | ||
862 | setOrderCheckType(CHECK_TYPE.NORMAL); | 1088 | setOrderCheckType(CHECK_TYPE.NORMAL); |
863 | }} | 1089 | }} |
864 | > | 1090 | > |
865 | - 打印 | 1091 | + 仓库打印 |
866 | </Button> | 1092 | </Button> |
867 | ) : ( | 1093 | ) : ( |
868 | '' | 1094 | '' |
869 | )} | 1095 | )} |
870 | 1096 | ||
871 | - {record.mainPath.includes('supplierPrint') ? ( | 1097 | + {record.mainPath?.includes('supplierPrint') ? ( |
872 | <Button | 1098 | <Button |
873 | className="p-0" | 1099 | className="p-0" |
874 | type="link" | 1100 | type="link" |
@@ -882,13 +1108,13 @@ const OrderPage = () => { | @@ -882,13 +1108,13 @@ const OrderPage = () => { | ||
882 | setOrderCheckType(CHECK_TYPE.SUPPLIER); | 1108 | setOrderCheckType(CHECK_TYPE.SUPPLIER); |
883 | }} | 1109 | }} |
884 | > | 1110 | > |
885 | - 打印 | 1111 | + 供应商打印 |
886 | </Button> | 1112 | </Button> |
887 | ) : ( | 1113 | ) : ( |
888 | '' | 1114 | '' |
889 | )} | 1115 | )} |
890 | 1116 | ||
891 | - {record.mainPath.includes('rePrintOrder') ? ( | 1117 | + {record.mainPath?.includes('rePrintOrder') ? ( |
892 | <Button | 1118 | <Button |
893 | className="p-0" | 1119 | className="p-0" |
894 | type="link" | 1120 | type="link" |
@@ -907,7 +1133,7 @@ const OrderPage = () => { | @@ -907,7 +1133,7 @@ const OrderPage = () => { | ||
907 | ) : ( | 1133 | ) : ( |
908 | '' | 1134 | '' |
909 | )} | 1135 | )} |
910 | - {record.mainPath.includes('modifySendInformation') ? ( | 1136 | + {record.mainPath?.includes('modifySendInformation') ? ( |
911 | <Button | 1137 | <Button |
912 | className="p-0" | 1138 | className="p-0" |
913 | type="link" | 1139 | type="link" |
@@ -937,7 +1163,7 @@ const OrderPage = () => { | @@ -937,7 +1163,7 @@ const OrderPage = () => { | ||
937 | ) : ( | 1163 | ) : ( |
938 | '' | 1164 | '' |
939 | )} | 1165 | )} |
940 | - {record.mainPath.includes('invoicing') ? ( | 1166 | + {record.mainPath?.includes('invoicing') ? ( |
941 | <Button | 1167 | <Button |
942 | type="link" | 1168 | type="link" |
943 | className="p-0" | 1169 | className="p-0" |
@@ -960,7 +1186,7 @@ const OrderPage = () => { | @@ -960,7 +1186,7 @@ const OrderPage = () => { | ||
960 | ) : ( | 1186 | ) : ( |
961 | '' | 1187 | '' |
962 | )} | 1188 | )} |
963 | - {record.mainPath.includes('updateOrder') ? ( | 1189 | + {record.mainPath?.includes('updateOrder') ? ( |
964 | <Button | 1190 | <Button |
965 | className="p-0" | 1191 | className="p-0" |
966 | type="link" | 1192 | type="link" |
@@ -1003,7 +1229,7 @@ const OrderPage = () => { | @@ -1003,7 +1229,7 @@ const OrderPage = () => { | ||
1003 | '' | 1229 | '' |
1004 | )} | 1230 | )} |
1005 | 1231 | ||
1006 | - {record.mainPath.includes('checkOrder') ? ( | 1232 | + {record.mainPath?.includes('checkOrder') ? ( |
1007 | <Button | 1233 | <Button |
1008 | className="p-0" | 1234 | className="p-0" |
1009 | type="link" | 1235 | type="link" |
@@ -1034,8 +1260,48 @@ const OrderPage = () => { | @@ -1034,8 +1260,48 @@ const OrderPage = () => { | ||
1034 | '' | 1260 | '' |
1035 | )} | 1261 | )} |
1036 | 1262 | ||
1263 | + {record.mainPath?.includes('noNeedSend') ? ( | ||
1264 | + <ButtonConfirm | ||
1265 | + className="p-0" | ||
1266 | + title="此订单是否无需发货?" | ||
1267 | + text="无需发货" | ||
1268 | + onConfirm={async () => { | ||
1269 | + let selectedSubOrders = selectedRowObj[record.id]; | ||
1270 | + if (selectedSubOrders === undefined) { | ||
1271 | + selectedSubOrders = record.subOrderInformationLists; | ||
1272 | + } | ||
1273 | + setSelectedRows(selectedSubOrders); | ||
1274 | + for (let i = 0; i < selectedSubOrders.length; i++) { | ||
1275 | + if ( | ||
1276 | + selectedSubOrders[i].orderStatus !== | ||
1277 | + 'CONFIRM_RECEIPT' | ||
1278 | + ) { | ||
1279 | + message.error( | ||
1280 | + '请选择未发货的子订单进行无需发货操作', | ||
1281 | + ); | ||
1282 | + return; | ||
1283 | + } | ||
1284 | + } | ||
1285 | + | ||
1286 | + const data = await postServiceOrderNoNeedSend({ | ||
1287 | + data: { | ||
1288 | + ids: selectedSubOrders.map((item) => { | ||
1289 | + return item.id; | ||
1290 | + }), | ||
1291 | + }, | ||
1292 | + }); | ||
1293 | + if (data.result === RESPONSE_CODE.SUCCESS) { | ||
1294 | + message.success(data.message); | ||
1295 | + refreshTable(); | ||
1296 | + } | ||
1297 | + }} | ||
1298 | + /> | ||
1299 | + ) : ( | ||
1300 | + '' | ||
1301 | + )} | ||
1302 | + | ||
1037 | {/* 财务审核:主订单暂无 */} | 1303 | {/* 财务审核:主订单暂无 */} |
1038 | - {record.mainPath.includes('financeCheckOrder') ? ( | 1304 | + {record.mainPath?.includes('financeCheckOrder') ? ( |
1039 | <Button | 1305 | <Button |
1040 | className="p-0" | 1306 | className="p-0" |
1041 | type="link" | 1307 | type="link" |
@@ -1070,7 +1336,7 @@ const OrderPage = () => { | @@ -1070,7 +1336,7 @@ const OrderPage = () => { | ||
1070 | )} | 1336 | )} |
1071 | 1337 | ||
1072 | {/* 采购审核 */} | 1338 | {/* 采购审核 */} |
1073 | - {record.mainPath.includes('procureCheckOrder') ? ( | 1339 | + {record.mainPath?.includes('procureCheckOrder') ? ( |
1074 | <Button | 1340 | <Button |
1075 | className="p-0" | 1341 | className="p-0" |
1076 | type="link" | 1342 | type="link" |
@@ -1103,7 +1369,80 @@ const OrderPage = () => { | @@ -1103,7 +1369,80 @@ const OrderPage = () => { | ||
1103 | '' | 1369 | '' |
1104 | )} | 1370 | )} |
1105 | 1371 | ||
1106 | - {record.mainPath.includes('orderCancel') ? ( | 1372 | + {record.mainPath?.includes('applyAfterSales') ? ( |
1373 | + <Button | ||
1374 | + className="p-0" | ||
1375 | + type="link" | ||
1376 | + onClick={() => { | ||
1377 | + let selectedSubOrders = selectedRowObj[record.id]; | ||
1378 | + if (selectedSubOrders === undefined) { | ||
1379 | + selectedSubOrders = record.subOrderInformationLists; | ||
1380 | + } | ||
1381 | + setSelectedRows(selectedSubOrders); | ||
1382 | + for (let i = 0; i < selectedSubOrders.length; i++) { | ||
1383 | + if ( | ||
1384 | + selectedSubOrders[i].orderStatus !== | ||
1385 | + 'CONFIRM_RECEIPT' | ||
1386 | + ) { | ||
1387 | + message.error('请选择确认收货状态的子订单进行售后'); | ||
1388 | + return; | ||
1389 | + } | ||
1390 | + } | ||
1391 | + setAfterSalesDrawerVisible(true); | ||
1392 | + setOrderRow(record); | ||
1393 | + }} | ||
1394 | + > | ||
1395 | + 申请售后 | ||
1396 | + </Button> | ||
1397 | + ) : ( | ||
1398 | + '' | ||
1399 | + )} | ||
1400 | + | ||
1401 | + {record.mainPath?.includes('afterSalesCompletion') ? ( | ||
1402 | + <ButtonConfirm | ||
1403 | + className="p-0" | ||
1404 | + title="售后是否已完成?" | ||
1405 | + text="完成售后" | ||
1406 | + onConfirm={async () => { | ||
1407 | + let selectedSubOrders = selectedRowObj[record.id]; | ||
1408 | + if (selectedSubOrders === undefined) { | ||
1409 | + selectedSubOrders = record.subOrderInformationLists; | ||
1410 | + } | ||
1411 | + for (let i = 0; i < selectedSubOrders.length; i++) { | ||
1412 | + if ( | ||
1413 | + selectedSubOrders[i].orderStatus !== | ||
1414 | + 'IN_AFTER_SALES' | ||
1415 | + ) { | ||
1416 | + message.error( | ||
1417 | + '请选择售后中状态的子订单进行完成售后', | ||
1418 | + ); | ||
1419 | + return false; | ||
1420 | + } | ||
1421 | + } | ||
1422 | + | ||
1423 | + const ids = selectedSubOrders?.map((item) => { | ||
1424 | + return item.id; | ||
1425 | + }); | ||
1426 | + | ||
1427 | + let body = { | ||
1428 | + ids: ids, | ||
1429 | + }; | ||
1430 | + const data = await postServiceOrderAfterSalesCompletion( | ||
1431 | + { | ||
1432 | + data: body, | ||
1433 | + }, | ||
1434 | + ); | ||
1435 | + if (data.result === RESPONSE_CODE.SUCCESS) { | ||
1436 | + message.success(data.message); | ||
1437 | + refreshTable(); | ||
1438 | + } | ||
1439 | + }} | ||
1440 | + /> | ||
1441 | + ) : ( | ||
1442 | + '' | ||
1443 | + )} | ||
1444 | + | ||
1445 | + {record.mainPath?.includes('orderCancel') ? ( | ||
1107 | <ButtonConfirm | 1446 | <ButtonConfirm |
1108 | className="p-0" | 1447 | className="p-0" |
1109 | title="确认作废?" | 1448 | title="确认作废?" |
@@ -1125,6 +1464,26 @@ const OrderPage = () => { | @@ -1125,6 +1464,26 @@ const OrderPage = () => { | ||
1125 | ) : ( | 1464 | ) : ( |
1126 | '' | 1465 | '' |
1127 | )} | 1466 | )} |
1467 | + | ||
1468 | + {record.mainPath?.includes('procurePrint') ? ( | ||
1469 | + <Button | ||
1470 | + className="p-0" | ||
1471 | + type="link" | ||
1472 | + onClick={() => { | ||
1473 | + if (!selectedRowObj[record.id]?.length) { | ||
1474 | + return message.error('请选择选择子订单'); | ||
1475 | + } | ||
1476 | + setSelectedRows(selectedRowObj[record.id]); | ||
1477 | + setOrderRow(record); | ||
1478 | + setOrderPrintVisible(true); | ||
1479 | + setOrderCheckType(CHECK_TYPE.PROCURE); | ||
1480 | + }} | ||
1481 | + > | ||
1482 | + 采购打印 | ||
1483 | + </Button> | ||
1484 | + ) : ( | ||
1485 | + '' | ||
1486 | + )} | ||
1128 | </Space> | 1487 | </Space> |
1129 | </Space.Compact> | 1488 | </Space.Compact> |
1130 | </Flex> | 1489 | </Flex> |
@@ -1157,9 +1516,22 @@ const OrderPage = () => { | @@ -1157,9 +1516,22 @@ const OrderPage = () => { | ||
1157 | function toolBarRender() { | 1516 | function toolBarRender() { |
1158 | let toolBtns = []; | 1517 | let toolBtns = []; |
1159 | 1518 | ||
1519 | + toolBtns.push( | ||
1520 | + <Checkbox onChange={changeCancelOrderShow}>只看作废</Checkbox>, | ||
1521 | + ); | ||
1522 | + | ||
1160 | //导出按钮配置 | 1523 | //导出按钮配置 |
1161 | const items: MenuProps['items'] = [ | 1524 | const items: MenuProps['items'] = [ |
1162 | { | 1525 | { |
1526 | + label: '导出查询结果订单', | ||
1527 | + key: '2', | ||
1528 | + onClick: async () => { | ||
1529 | + let body = { flag: 50, ...searchParams }; | ||
1530 | + exportLoading(); | ||
1531 | + orderExport('/api/service/order/export', body, exportLoadingDestory); | ||
1532 | + }, | ||
1533 | + }, | ||
1534 | + { | ||
1163 | label: '导出已选中订单', | 1535 | label: '导出已选中订单', |
1164 | key: '1', | 1536 | key: '1', |
1165 | onClick: async () => { | 1537 | onClick: async () => { |
@@ -1172,15 +1544,24 @@ const OrderPage = () => { | @@ -1172,15 +1544,24 @@ const OrderPage = () => { | ||
1172 | orderExport('/api/service/order/export', body, exportLoadingDestory); | 1544 | orderExport('/api/service/order/export', body, exportLoadingDestory); |
1173 | }, | 1545 | }, |
1174 | }, | 1546 | }, |
1547 | + // { | ||
1548 | + // label: '导出当前页订单', | ||
1549 | + // key: '2', | ||
1550 | + // onClick: async () => { | ||
1551 | + // if (mainOrderAllItemKeys.length === 0) { | ||
1552 | + // message.error('当前没有订单'); | ||
1553 | + // return; | ||
1554 | + // } | ||
1555 | + // let body = { flag: 20, ids: mainOrderAllItemKeys }; | ||
1556 | + // exportLoading(); | ||
1557 | + // orderExport('/api/service/order/export', body, exportLoadingDestory); | ||
1558 | + // }, | ||
1559 | + // }, | ||
1175 | { | 1560 | { |
1176 | - label: '导出当前页订单', | ||
1177 | - key: '2', | 1561 | + label: '导出当天订单', |
1562 | + key: '4', | ||
1178 | onClick: async () => { | 1563 | onClick: async () => { |
1179 | - if (mainOrderAllItemKeys.length === 0) { | ||
1180 | - message.error('当前没有订单'); | ||
1181 | - return; | ||
1182 | - } | ||
1183 | - let body = { flag: 20, ids: mainOrderAllItemKeys }; | 1564 | + let body = { flag: 40, ids: [] }; |
1184 | exportLoading(); | 1565 | exportLoading(); |
1185 | orderExport('/api/service/order/export', body, exportLoadingDestory); | 1566 | orderExport('/api/service/order/export', body, exportLoadingDestory); |
1186 | }, | 1567 | }, |
@@ -1194,15 +1575,6 @@ const OrderPage = () => { | @@ -1194,15 +1575,6 @@ const OrderPage = () => { | ||
1194 | orderExport('/api/service/order/export', body, exportLoadingDestory); | 1575 | orderExport('/api/service/order/export', body, exportLoadingDestory); |
1195 | }, | 1576 | }, |
1196 | }, | 1577 | }, |
1197 | - { | ||
1198 | - label: '导出当天订单', | ||
1199 | - key: '4', | ||
1200 | - onClick: async () => { | ||
1201 | - let body = { flag: 40, ids: [] }; | ||
1202 | - exportLoading(); | ||
1203 | - orderExport('/api/service/order/export', body, exportLoadingDestory); | ||
1204 | - }, | ||
1205 | - }, | ||
1206 | ]; | 1578 | ]; |
1207 | 1579 | ||
1208 | const menuProps = { | 1580 | const menuProps = { |
@@ -1238,16 +1610,18 @@ const OrderPage = () => { | @@ -1238,16 +1610,18 @@ const OrderPage = () => { | ||
1238 | ); | 1610 | ); |
1239 | } | 1611 | } |
1240 | 1612 | ||
1241 | - toolBtns.push( | ||
1242 | - <Dropdown menu={menuProps}> | ||
1243 | - <Button> | ||
1244 | - <Space> | ||
1245 | - 导出 | ||
1246 | - <DownOutlined /> | ||
1247 | - </Space> | ||
1248 | - </Button> | ||
1249 | - </Dropdown>, | ||
1250 | - ); | 1613 | + if (rolePath?.includes('export')) { |
1614 | + toolBtns.push( | ||
1615 | + <Dropdown menu={menuProps}> | ||
1616 | + <Button> | ||
1617 | + <Space> | ||
1618 | + 导出 | ||
1619 | + <DownOutlined /> | ||
1620 | + </Space> | ||
1621 | + </Button> | ||
1622 | + </Dropdown>, | ||
1623 | + ); | ||
1624 | + } | ||
1251 | 1625 | ||
1252 | // toolBtns.push( | 1626 | // toolBtns.push( |
1253 | // <Button | 1627 | // <Button |
@@ -1338,13 +1712,15 @@ const OrderPage = () => { | @@ -1338,13 +1712,15 @@ const OrderPage = () => { | ||
1338 | sorter, | 1712 | sorter, |
1339 | filter, | 1713 | filter, |
1340 | ) => { | 1714 | ) => { |
1715 | + //保存这个搜索条件 | ||
1716 | + setSearchParam(params); | ||
1341 | const { data } = await postServiceOrderQueryServiceOrder({ | 1717 | const { data } = await postServiceOrderQueryServiceOrder({ |
1342 | // ...params, | 1718 | // ...params, |
1343 | // FIXME: remove @ts-ignore | 1719 | // FIXME: remove @ts-ignore |
1344 | // @ts-ignore | 1720 | // @ts-ignore |
1345 | sorter, | 1721 | sorter, |
1346 | filter, | 1722 | filter, |
1347 | - data: params, | 1723 | + data: { ...params, isDeleteQueryOrder: onlyShowCancelOrder }, |
1348 | }); | 1724 | }); |
1349 | 1725 | ||
1350 | let mainOrderIds = data?.data?.map((d) => d.id); | 1726 | let mainOrderIds = data?.data?.map((d) => d.id); |
@@ -1508,6 +1884,7 @@ const OrderPage = () => { | @@ -1508,6 +1884,7 @@ const OrderPage = () => { | ||
1508 | {historyModalVisible && ( | 1884 | {historyModalVisible && ( |
1509 | <HistoryModal | 1885 | <HistoryModal |
1510 | subOrders={selectedRows} | 1886 | subOrders={selectedRows} |
1887 | + isCancelledOrder={onlyShowCancelOrder} | ||
1511 | onClose={() => { | 1888 | onClose={() => { |
1512 | setHistoryModalVisible(false); | 1889 | setHistoryModalVisible(false); |
1513 | setSelectedRows({}); | 1890 | setSelectedRows({}); |
@@ -1549,6 +1926,20 @@ const OrderPage = () => { | @@ -1549,6 +1926,20 @@ const OrderPage = () => { | ||
1549 | /> | 1926 | /> |
1550 | )} | 1927 | )} |
1551 | 1928 | ||
1929 | + {afterSalesDrawerVisible && ( | ||
1930 | + <AfterSalesDrawer | ||
1931 | + setVisible={setAfterSalesDrawerVisible} | ||
1932 | + mainOrder={orderRow} | ||
1933 | + subOrders={selectedRows} | ||
1934 | + onClose={() => { | ||
1935 | + setAfterSalesDrawerVisible(false); | ||
1936 | + setSelectedRows({}); | ||
1937 | + setOrderRow({}); | ||
1938 | + refreshTable(); | ||
1939 | + }} | ||
1940 | + /> | ||
1941 | + )} | ||
1942 | + | ||
1552 | {contextHolder} | 1943 | {contextHolder} |
1553 | </PageContainer> | 1944 | </PageContainer> |
1554 | ); | 1945 | ); |
src/pages/OrderPrint/OrderPrintModal.tsx
@@ -2,6 +2,7 @@ import { RESPONSE_CODE } from '@/constants/enum'; | @@ -2,6 +2,7 @@ import { RESPONSE_CODE } from '@/constants/enum'; | ||
2 | import '@/pages/OrderPrint/index.less'; | 2 | import '@/pages/OrderPrint/index.less'; |
3 | import { | 3 | import { |
4 | postServiceOrderPrintOrder, | 4 | postServiceOrderPrintOrder, |
5 | + postServiceOrderProcurePrint, | ||
5 | postServiceOrderSupplierPrint, | 6 | postServiceOrderSupplierPrint, |
6 | } from '@/services'; | 7 | } from '@/services'; |
7 | import { ExclamationCircleFilled } from '@ant-design/icons'; | 8 | import { ExclamationCircleFilled } from '@ant-design/icons'; |
@@ -66,6 +67,14 @@ export default ({ | @@ -66,6 +67,14 @@ export default ({ | ||
66 | }), | 67 | }), |
67 | }, | 68 | }, |
68 | }); | 69 | }); |
70 | + } else if (optType(CHECK_TYPE.PROCURE)) { | ||
71 | + res = await postServiceOrderProcurePrint({ | ||
72 | + data: { | ||
73 | + ids: subOrders.map((item) => { | ||
74 | + return item.id; | ||
75 | + }), | ||
76 | + }, | ||
77 | + }); | ||
69 | } else { | 78 | } else { |
70 | res = await postServiceOrderPrintOrder({ data: body }); | 79 | res = await postServiceOrderPrintOrder({ data: body }); |
71 | } | 80 | } |
src/services/definition.ts
@@ -699,11 +699,24 @@ export interface ProcureCheckOrderDto { | @@ -699,11 +699,24 @@ export interface ProcureCheckOrderDto { | ||
699 | ids?: Array<number>; | 699 | ids?: Array<number>; |
700 | /** | 700 | /** |
701 | * @description | 701 | * @description |
702 | - * 采购人姓名 | 702 | + * true表示采购走打印发货流程,false表示选择供应商进行发货 |
703 | + */ | ||
704 | + procureIsPrintAndSend?: boolean; | ||
705 | + /** | ||
706 | + * @description | ||
707 | + * 供应商姓名 | ||
703 | */ | 708 | */ |
704 | supplier?: string; | 709 | supplier?: string; |
705 | } | 710 | } |
706 | 711 | ||
712 | +export interface ProcurePrintDto { | ||
713 | + /** | ||
714 | + * @description | ||
715 | + * 子订单id集合 | ||
716 | + */ | ||
717 | + ids?: Array<number>; | ||
718 | +} | ||
719 | + | ||
707 | export interface ProductInformationDto { | 720 | export interface ProductInformationDto { |
708 | /** | 721 | /** |
709 | * @description | 722 | * @description |
src/services/request.ts
@@ -26,7 +26,6 @@ import type { | @@ -26,7 +26,6 @@ import type { | ||
26 | DictionaryQueryVO, | 26 | DictionaryQueryVO, |
27 | DictionaryVO, | 27 | DictionaryVO, |
28 | Dto, | 28 | Dto, |
29 | - ModelAndView, | ||
30 | OrderAddVO, | 29 | OrderAddVO, |
31 | OrderAuditLogQueryVO, | 30 | OrderAuditLogQueryVO, |
32 | OrderBaseInfoQueryVO, | 31 | OrderBaseInfoQueryVO, |
@@ -36,6 +35,7 @@ import type { | @@ -36,6 +35,7 @@ import type { | ||
36 | OrderUnlockFieldApplyVO, | 35 | OrderUnlockFieldApplyVO, |
37 | OrderUpdateVO, | 36 | OrderUpdateVO, |
38 | ProcureCheckOrderDto, | 37 | ProcureCheckOrderDto, |
38 | + ProcurePrintDto, | ||
39 | ProductInformationDto, | 39 | ProductInformationDto, |
40 | QueryAnnexDto, | 40 | QueryAnnexDto, |
41 | QueryHistoryRecordDto, | 41 | QueryHistoryRecordDto, |
@@ -223,7 +223,9 @@ export interface GetErrorResponse { | @@ -223,7 +223,9 @@ export interface GetErrorResponse { | ||
223 | * @description | 223 | * @description |
224 | * OK | 224 | * OK |
225 | */ | 225 | */ |
226 | - 200: ModelAndView; | 226 | + 200: { |
227 | + [propertyName: string]: any; | ||
228 | + }; | ||
227 | /** | 229 | /** |
228 | * @description | 230 | * @description |
229 | * Unauthorized | 231 | * Unauthorized |
@@ -244,9 +246,9 @@ export interface GetErrorResponse { | @@ -244,9 +246,9 @@ export interface GetErrorResponse { | ||
244 | export type GetErrorResponseSuccess = GetErrorResponse[200]; | 246 | export type GetErrorResponseSuccess = GetErrorResponse[200]; |
245 | /** | 247 | /** |
246 | * @description | 248 | * @description |
247 | - * errorHtml | 249 | + * error |
248 | * @tags basic-error-controller | 250 | * @tags basic-error-controller |
249 | - * @produces text/html | 251 | + * @produces * |
250 | */ | 252 | */ |
251 | export const getError = /* #__PURE__ */ (() => { | 253 | export const getError = /* #__PURE__ */ (() => { |
252 | const method = 'get'; | 254 | const method = 'get'; |
@@ -270,7 +272,9 @@ export interface PutErrorResponse { | @@ -270,7 +272,9 @@ export interface PutErrorResponse { | ||
270 | * @description | 272 | * @description |
271 | * OK | 273 | * OK |
272 | */ | 274 | */ |
273 | - 200: ModelAndView; | 275 | + 200: { |
276 | + [propertyName: string]: any; | ||
277 | + }; | ||
274 | /** | 278 | /** |
275 | * @description | 279 | * @description |
276 | * Created | 280 | * Created |
@@ -296,9 +300,9 @@ export interface PutErrorResponse { | @@ -296,9 +300,9 @@ export interface PutErrorResponse { | ||
296 | export type PutErrorResponseSuccess = PutErrorResponse[200]; | 300 | export type PutErrorResponseSuccess = PutErrorResponse[200]; |
297 | /** | 301 | /** |
298 | * @description | 302 | * @description |
299 | - * errorHtml | 303 | + * error |
300 | * @tags basic-error-controller | 304 | * @tags basic-error-controller |
301 | - * @produces text/html | 305 | + * @produces * |
302 | * @consumes application/json | 306 | * @consumes application/json |
303 | */ | 307 | */ |
304 | export const putError = /* #__PURE__ */ (() => { | 308 | export const putError = /* #__PURE__ */ (() => { |
@@ -323,7 +327,9 @@ export interface PostErrorResponse { | @@ -323,7 +327,9 @@ export interface PostErrorResponse { | ||
323 | * @description | 327 | * @description |
324 | * OK | 328 | * OK |
325 | */ | 329 | */ |
326 | - 200: ModelAndView; | 330 | + 200: { |
331 | + [propertyName: string]: any; | ||
332 | + }; | ||
327 | /** | 333 | /** |
328 | * @description | 334 | * @description |
329 | * Created | 335 | * Created |
@@ -349,9 +355,9 @@ export interface PostErrorResponse { | @@ -349,9 +355,9 @@ export interface PostErrorResponse { | ||
349 | export type PostErrorResponseSuccess = PostErrorResponse[200]; | 355 | export type PostErrorResponseSuccess = PostErrorResponse[200]; |
350 | /** | 356 | /** |
351 | * @description | 357 | * @description |
352 | - * errorHtml | 358 | + * error |
353 | * @tags basic-error-controller | 359 | * @tags basic-error-controller |
354 | - * @produces text/html | 360 | + * @produces * |
355 | * @consumes application/json | 361 | * @consumes application/json |
356 | */ | 362 | */ |
357 | export const postError = /* #__PURE__ */ (() => { | 363 | export const postError = /* #__PURE__ */ (() => { |
@@ -376,7 +382,9 @@ export interface DeleteErrorResponse { | @@ -376,7 +382,9 @@ export interface DeleteErrorResponse { | ||
376 | * @description | 382 | * @description |
377 | * OK | 383 | * OK |
378 | */ | 384 | */ |
379 | - 200: ModelAndView; | 385 | + 200: { |
386 | + [propertyName: string]: any; | ||
387 | + }; | ||
380 | /** | 388 | /** |
381 | * @description | 389 | * @description |
382 | * No Content | 390 | * No Content |
@@ -397,9 +405,9 @@ export interface DeleteErrorResponse { | @@ -397,9 +405,9 @@ export interface DeleteErrorResponse { | ||
397 | export type DeleteErrorResponseSuccess = DeleteErrorResponse[200]; | 405 | export type DeleteErrorResponseSuccess = DeleteErrorResponse[200]; |
398 | /** | 406 | /** |
399 | * @description | 407 | * @description |
400 | - * errorHtml | 408 | + * error |
401 | * @tags basic-error-controller | 409 | * @tags basic-error-controller |
402 | - * @produces text/html | 410 | + * @produces * |
403 | */ | 411 | */ |
404 | export const deleteError = /* #__PURE__ */ (() => { | 412 | export const deleteError = /* #__PURE__ */ (() => { |
405 | const method = 'delete'; | 413 | const method = 'delete'; |
@@ -423,7 +431,9 @@ export interface OptionsErrorResponse { | @@ -423,7 +431,9 @@ export interface OptionsErrorResponse { | ||
423 | * @description | 431 | * @description |
424 | * OK | 432 | * OK |
425 | */ | 433 | */ |
426 | - 200: ModelAndView; | 434 | + 200: { |
435 | + [propertyName: string]: any; | ||
436 | + }; | ||
427 | /** | 437 | /** |
428 | * @description | 438 | * @description |
429 | * No Content | 439 | * No Content |
@@ -444,9 +454,9 @@ export interface OptionsErrorResponse { | @@ -444,9 +454,9 @@ export interface OptionsErrorResponse { | ||
444 | export type OptionsErrorResponseSuccess = OptionsErrorResponse[200]; | 454 | export type OptionsErrorResponseSuccess = OptionsErrorResponse[200]; |
445 | /** | 455 | /** |
446 | * @description | 456 | * @description |
447 | - * errorHtml | 457 | + * error |
448 | * @tags basic-error-controller | 458 | * @tags basic-error-controller |
449 | - * @produces text/html | 459 | + * @produces * |
450 | * @consumes application/json | 460 | * @consumes application/json |
451 | */ | 461 | */ |
452 | export const optionsError = /* #__PURE__ */ (() => { | 462 | export const optionsError = /* #__PURE__ */ (() => { |
@@ -471,7 +481,9 @@ export interface HeadErrorResponse { | @@ -471,7 +481,9 @@ export interface HeadErrorResponse { | ||
471 | * @description | 481 | * @description |
472 | * OK | 482 | * OK |
473 | */ | 483 | */ |
474 | - 200: ModelAndView; | 484 | + 200: { |
485 | + [propertyName: string]: any; | ||
486 | + }; | ||
475 | /** | 487 | /** |
476 | * @description | 488 | * @description |
477 | * No Content | 489 | * No Content |
@@ -492,9 +504,9 @@ export interface HeadErrorResponse { | @@ -492,9 +504,9 @@ export interface HeadErrorResponse { | ||
492 | export type HeadErrorResponseSuccess = HeadErrorResponse[200]; | 504 | export type HeadErrorResponseSuccess = HeadErrorResponse[200]; |
493 | /** | 505 | /** |
494 | * @description | 506 | * @description |
495 | - * errorHtml | 507 | + * error |
496 | * @tags basic-error-controller | 508 | * @tags basic-error-controller |
497 | - * @produces text/html | 509 | + * @produces * |
498 | * @consumes application/json | 510 | * @consumes application/json |
499 | */ | 511 | */ |
500 | export const headError = /* #__PURE__ */ (() => { | 512 | export const headError = /* #__PURE__ */ (() => { |
@@ -519,7 +531,9 @@ export interface PatchErrorResponse { | @@ -519,7 +531,9 @@ export interface PatchErrorResponse { | ||
519 | * @description | 531 | * @description |
520 | * OK | 532 | * OK |
521 | */ | 533 | */ |
522 | - 200: ModelAndView; | 534 | + 200: { |
535 | + [propertyName: string]: any; | ||
536 | + }; | ||
523 | /** | 537 | /** |
524 | * @description | 538 | * @description |
525 | * No Content | 539 | * No Content |
@@ -540,9 +554,9 @@ export interface PatchErrorResponse { | @@ -540,9 +554,9 @@ export interface PatchErrorResponse { | ||
540 | export type PatchErrorResponseSuccess = PatchErrorResponse[200]; | 554 | export type PatchErrorResponseSuccess = PatchErrorResponse[200]; |
541 | /** | 555 | /** |
542 | * @description | 556 | * @description |
543 | - * errorHtml | 557 | + * error |
544 | * @tags basic-error-controller | 558 | * @tags basic-error-controller |
545 | - * @produces text/html | 559 | + * @produces * |
546 | * @consumes application/json | 560 | * @consumes application/json |
547 | */ | 561 | */ |
548 | export const patchError = /* #__PURE__ */ (() => { | 562 | export const patchError = /* #__PURE__ */ (() => { |
@@ -4771,6 +4785,148 @@ export const postServiceOrderAddOrder = /* #__PURE__ */ (() => { | @@ -4771,6 +4785,148 @@ export const postServiceOrderAddOrder = /* #__PURE__ */ (() => { | ||
4771 | return request; | 4785 | return request; |
4772 | })(); | 4786 | })(); |
4773 | 4787 | ||
4788 | +/** @description request parameter type for postServiceOrderAfterSalesCompletion */ | ||
4789 | +export interface PostServiceOrderAfterSalesCompletionOption { | ||
4790 | + /** | ||
4791 | + * @description | ||
4792 | + * dto | ||
4793 | + */ | ||
4794 | + body: { | ||
4795 | + /** | ||
4796 | + @description | ||
4797 | + dto */ | ||
4798 | + dto: Dto; | ||
4799 | + }; | ||
4800 | +} | ||
4801 | + | ||
4802 | +/** @description response type for postServiceOrderAfterSalesCompletion */ | ||
4803 | +export interface PostServiceOrderAfterSalesCompletionResponse { | ||
4804 | + /** | ||
4805 | + * @description | ||
4806 | + * OK | ||
4807 | + */ | ||
4808 | + 200: ServerResult; | ||
4809 | + /** | ||
4810 | + * @description | ||
4811 | + * Created | ||
4812 | + */ | ||
4813 | + 201: any; | ||
4814 | + /** | ||
4815 | + * @description | ||
4816 | + * Unauthorized | ||
4817 | + */ | ||
4818 | + 401: any; | ||
4819 | + /** | ||
4820 | + * @description | ||
4821 | + * Forbidden | ||
4822 | + */ | ||
4823 | + 403: any; | ||
4824 | + /** | ||
4825 | + * @description | ||
4826 | + * Not Found | ||
4827 | + */ | ||
4828 | + 404: any; | ||
4829 | +} | ||
4830 | + | ||
4831 | +export type PostServiceOrderAfterSalesCompletionResponseSuccess = | ||
4832 | + PostServiceOrderAfterSalesCompletionResponse[200]; | ||
4833 | +/** | ||
4834 | + * @description | ||
4835 | + * 售后完成 | ||
4836 | + * @tags 内部订单 | ||
4837 | + * @produces * | ||
4838 | + * @consumes application/json | ||
4839 | + */ | ||
4840 | +export const postServiceOrderAfterSalesCompletion = /* #__PURE__ */ (() => { | ||
4841 | + const method = 'post'; | ||
4842 | + const url = '/service/order/afterSalesCompletion'; | ||
4843 | + function request( | ||
4844 | + option: PostServiceOrderAfterSalesCompletionOption, | ||
4845 | + ): Promise<PostServiceOrderAfterSalesCompletionResponseSuccess> { | ||
4846 | + return requester(request.url, { | ||
4847 | + method: request.method, | ||
4848 | + ...option, | ||
4849 | + }) as unknown as Promise<PostServiceOrderAfterSalesCompletionResponseSuccess>; | ||
4850 | + } | ||
4851 | + | ||
4852 | + /** http method */ | ||
4853 | + request.method = method; | ||
4854 | + /** request url */ | ||
4855 | + request.url = url; | ||
4856 | + return request; | ||
4857 | +})(); | ||
4858 | + | ||
4859 | +/** @description request parameter type for postServiceOrderApplyAfterSales */ | ||
4860 | +export interface PostServiceOrderApplyAfterSalesOption { | ||
4861 | + /** | ||
4862 | + * @description | ||
4863 | + * dto | ||
4864 | + */ | ||
4865 | + body: { | ||
4866 | + /** | ||
4867 | + @description | ||
4868 | + dto */ | ||
4869 | + dto: Dto; | ||
4870 | + }; | ||
4871 | +} | ||
4872 | + | ||
4873 | +/** @description response type for postServiceOrderApplyAfterSales */ | ||
4874 | +export interface PostServiceOrderApplyAfterSalesResponse { | ||
4875 | + /** | ||
4876 | + * @description | ||
4877 | + * OK | ||
4878 | + */ | ||
4879 | + 200: ServerResult; | ||
4880 | + /** | ||
4881 | + * @description | ||
4882 | + * Created | ||
4883 | + */ | ||
4884 | + 201: any; | ||
4885 | + /** | ||
4886 | + * @description | ||
4887 | + * Unauthorized | ||
4888 | + */ | ||
4889 | + 401: any; | ||
4890 | + /** | ||
4891 | + * @description | ||
4892 | + * Forbidden | ||
4893 | + */ | ||
4894 | + 403: any; | ||
4895 | + /** | ||
4896 | + * @description | ||
4897 | + * Not Found | ||
4898 | + */ | ||
4899 | + 404: any; | ||
4900 | +} | ||
4901 | + | ||
4902 | +export type PostServiceOrderApplyAfterSalesResponseSuccess = | ||
4903 | + PostServiceOrderApplyAfterSalesResponse[200]; | ||
4904 | +/** | ||
4905 | + * @description | ||
4906 | + * 申请售后 | ||
4907 | + * @tags 内部订单 | ||
4908 | + * @produces * | ||
4909 | + * @consumes application/json | ||
4910 | + */ | ||
4911 | +export const postServiceOrderApplyAfterSales = /* #__PURE__ */ (() => { | ||
4912 | + const method = 'post'; | ||
4913 | + const url = '/service/order/applyAfterSales'; | ||
4914 | + function request( | ||
4915 | + option: PostServiceOrderApplyAfterSalesOption, | ||
4916 | + ): Promise<PostServiceOrderApplyAfterSalesResponseSuccess> { | ||
4917 | + return requester(request.url, { | ||
4918 | + method: request.method, | ||
4919 | + ...option, | ||
4920 | + }) as unknown as Promise<PostServiceOrderApplyAfterSalesResponseSuccess>; | ||
4921 | + } | ||
4922 | + | ||
4923 | + /** http method */ | ||
4924 | + request.method = method; | ||
4925 | + /** request url */ | ||
4926 | + request.url = url; | ||
4927 | + return request; | ||
4928 | +})(); | ||
4929 | + | ||
4774 | /** @description request parameter type for postServiceOrderCheckOrder */ | 4930 | /** @description request parameter type for postServiceOrderCheckOrder */ |
4775 | export interface PostServiceOrderCheckOrderOption { | 4931 | export interface PostServiceOrderCheckOrderOption { |
4776 | /** | 4932 | /** |
@@ -5551,6 +5707,77 @@ export const postServiceOrderInvoicing = /* #__PURE__ */ (() => { | @@ -5551,6 +5707,77 @@ export const postServiceOrderInvoicing = /* #__PURE__ */ (() => { | ||
5551 | return request; | 5707 | return request; |
5552 | })(); | 5708 | })(); |
5553 | 5709 | ||
5710 | +/** @description request parameter type for postServiceOrderNoNeedSend */ | ||
5711 | +export interface PostServiceOrderNoNeedSendOption { | ||
5712 | + /** | ||
5713 | + * @description | ||
5714 | + * dto | ||
5715 | + */ | ||
5716 | + body: { | ||
5717 | + /** | ||
5718 | + @description | ||
5719 | + dto */ | ||
5720 | + dto: Dto; | ||
5721 | + }; | ||
5722 | +} | ||
5723 | + | ||
5724 | +/** @description response type for postServiceOrderNoNeedSend */ | ||
5725 | +export interface PostServiceOrderNoNeedSendResponse { | ||
5726 | + /** | ||
5727 | + * @description | ||
5728 | + * OK | ||
5729 | + */ | ||
5730 | + 200: ServerResult; | ||
5731 | + /** | ||
5732 | + * @description | ||
5733 | + * Created | ||
5734 | + */ | ||
5735 | + 201: any; | ||
5736 | + /** | ||
5737 | + * @description | ||
5738 | + * Unauthorized | ||
5739 | + */ | ||
5740 | + 401: any; | ||
5741 | + /** | ||
5742 | + * @description | ||
5743 | + * Forbidden | ||
5744 | + */ | ||
5745 | + 403: any; | ||
5746 | + /** | ||
5747 | + * @description | ||
5748 | + * Not Found | ||
5749 | + */ | ||
5750 | + 404: any; | ||
5751 | +} | ||
5752 | + | ||
5753 | +export type PostServiceOrderNoNeedSendResponseSuccess = | ||
5754 | + PostServiceOrderNoNeedSendResponse[200]; | ||
5755 | +/** | ||
5756 | + * @description | ||
5757 | + * 无需发货 | ||
5758 | + * @tags 内部订单 | ||
5759 | + * @produces * | ||
5760 | + * @consumes application/json | ||
5761 | + */ | ||
5762 | +export const postServiceOrderNoNeedSend = /* #__PURE__ */ (() => { | ||
5763 | + const method = 'post'; | ||
5764 | + const url = '/service/order/noNeedSend'; | ||
5765 | + function request( | ||
5766 | + option: PostServiceOrderNoNeedSendOption, | ||
5767 | + ): Promise<PostServiceOrderNoNeedSendResponseSuccess> { | ||
5768 | + return requester(request.url, { | ||
5769 | + method: request.method, | ||
5770 | + ...option, | ||
5771 | + }) as unknown as Promise<PostServiceOrderNoNeedSendResponseSuccess>; | ||
5772 | + } | ||
5773 | + | ||
5774 | + /** http method */ | ||
5775 | + request.method = method; | ||
5776 | + /** request url */ | ||
5777 | + request.url = url; | ||
5778 | + return request; | ||
5779 | +})(); | ||
5780 | + | ||
5554 | /** @description request parameter type for postServiceOrderOrderCancel */ | 5781 | /** @description request parameter type for postServiceOrderOrderCancel */ |
5555 | export interface PostServiceOrderOrderCancelOption { | 5782 | export interface PostServiceOrderOrderCancelOption { |
5556 | /** | 5783 | /** |
@@ -5764,6 +5991,148 @@ export const postServiceOrderProcureCheckOrder = /* #__PURE__ */ (() => { | @@ -5764,6 +5991,148 @@ export const postServiceOrderProcureCheckOrder = /* #__PURE__ */ (() => { | ||
5764 | return request; | 5991 | return request; |
5765 | })(); | 5992 | })(); |
5766 | 5993 | ||
5994 | +/** @description request parameter type for postServiceOrderProcurePrint */ | ||
5995 | +export interface PostServiceOrderProcurePrintOption { | ||
5996 | + /** | ||
5997 | + * @description | ||
5998 | + * dto | ||
5999 | + */ | ||
6000 | + body: { | ||
6001 | + /** | ||
6002 | + @description | ||
6003 | + dto */ | ||
6004 | + dto: ProcurePrintDto; | ||
6005 | + }; | ||
6006 | +} | ||
6007 | + | ||
6008 | +/** @description response type for postServiceOrderProcurePrint */ | ||
6009 | +export interface PostServiceOrderProcurePrintResponse { | ||
6010 | + /** | ||
6011 | + * @description | ||
6012 | + * OK | ||
6013 | + */ | ||
6014 | + 200: ServerResult; | ||
6015 | + /** | ||
6016 | + * @description | ||
6017 | + * Created | ||
6018 | + */ | ||
6019 | + 201: any; | ||
6020 | + /** | ||
6021 | + * @description | ||
6022 | + * Unauthorized | ||
6023 | + */ | ||
6024 | + 401: any; | ||
6025 | + /** | ||
6026 | + * @description | ||
6027 | + * Forbidden | ||
6028 | + */ | ||
6029 | + 403: any; | ||
6030 | + /** | ||
6031 | + * @description | ||
6032 | + * Not Found | ||
6033 | + */ | ||
6034 | + 404: any; | ||
6035 | +} | ||
6036 | + | ||
6037 | +export type PostServiceOrderProcurePrintResponseSuccess = | ||
6038 | + PostServiceOrderProcurePrintResponse[200]; | ||
6039 | +/** | ||
6040 | + * @description | ||
6041 | + * 采购打印订单 | ||
6042 | + * @tags 内部订单 | ||
6043 | + * @produces * | ||
6044 | + * @consumes application/json | ||
6045 | + */ | ||
6046 | +export const postServiceOrderProcurePrint = /* #__PURE__ */ (() => { | ||
6047 | + const method = 'post'; | ||
6048 | + const url = '/service/order/procurePrint'; | ||
6049 | + function request( | ||
6050 | + option: PostServiceOrderProcurePrintOption, | ||
6051 | + ): Promise<PostServiceOrderProcurePrintResponseSuccess> { | ||
6052 | + return requester(request.url, { | ||
6053 | + method: request.method, | ||
6054 | + ...option, | ||
6055 | + }) as unknown as Promise<PostServiceOrderProcurePrintResponseSuccess>; | ||
6056 | + } | ||
6057 | + | ||
6058 | + /** http method */ | ||
6059 | + request.method = method; | ||
6060 | + /** request url */ | ||
6061 | + request.url = url; | ||
6062 | + return request; | ||
6063 | +})(); | ||
6064 | + | ||
6065 | +/** @description request parameter type for postServiceOrderProcureSend */ | ||
6066 | +export interface PostServiceOrderProcureSendOption { | ||
6067 | + /** | ||
6068 | + * @description | ||
6069 | + * dto | ||
6070 | + */ | ||
6071 | + body: { | ||
6072 | + /** | ||
6073 | + @description | ||
6074 | + dto */ | ||
6075 | + dto: Dto; | ||
6076 | + }; | ||
6077 | +} | ||
6078 | + | ||
6079 | +/** @description response type for postServiceOrderProcureSend */ | ||
6080 | +export interface PostServiceOrderProcureSendResponse { | ||
6081 | + /** | ||
6082 | + * @description | ||
6083 | + * OK | ||
6084 | + */ | ||
6085 | + 200: ServerResult; | ||
6086 | + /** | ||
6087 | + * @description | ||
6088 | + * Created | ||
6089 | + */ | ||
6090 | + 201: any; | ||
6091 | + /** | ||
6092 | + * @description | ||
6093 | + * Unauthorized | ||
6094 | + */ | ||
6095 | + 401: any; | ||
6096 | + /** | ||
6097 | + * @description | ||
6098 | + * Forbidden | ||
6099 | + */ | ||
6100 | + 403: any; | ||
6101 | + /** | ||
6102 | + * @description | ||
6103 | + * Not Found | ||
6104 | + */ | ||
6105 | + 404: any; | ||
6106 | +} | ||
6107 | + | ||
6108 | +export type PostServiceOrderProcureSendResponseSuccess = | ||
6109 | + PostServiceOrderProcureSendResponse[200]; | ||
6110 | +/** | ||
6111 | + * @description | ||
6112 | + * 采购发送订单 | ||
6113 | + * @tags 内部订单 | ||
6114 | + * @produces * | ||
6115 | + * @consumes application/json | ||
6116 | + */ | ||
6117 | +export const postServiceOrderProcureSend = /* #__PURE__ */ (() => { | ||
6118 | + const method = 'post'; | ||
6119 | + const url = '/service/order/procureSend'; | ||
6120 | + function request( | ||
6121 | + option: PostServiceOrderProcureSendOption, | ||
6122 | + ): Promise<PostServiceOrderProcureSendResponseSuccess> { | ||
6123 | + return requester(request.url, { | ||
6124 | + method: request.method, | ||
6125 | + ...option, | ||
6126 | + }) as unknown as Promise<PostServiceOrderProcureSendResponseSuccess>; | ||
6127 | + } | ||
6128 | + | ||
6129 | + /** http method */ | ||
6130 | + request.method = method; | ||
6131 | + /** request url */ | ||
6132 | + request.url = url; | ||
6133 | + return request; | ||
6134 | +})(); | ||
6135 | + | ||
5767 | /** @description response type for getServiceOrderProvideInvoicingStatus */ | 6136 | /** @description response type for getServiceOrderProvideInvoicingStatus */ |
5768 | export interface GetServiceOrderProvideInvoicingStatusResponse { | 6137 | export interface GetServiceOrderProvideInvoicingStatusResponse { |
5769 | /** | 6138 | /** |