diff --git a/src/api/wms/purchaseBarterRecordDetail/index.ts b/src/api/wms/purchaseBarterRecordDetail/index.ts index 91bd582f9..478a529ed 100644 --- a/src/api/wms/purchaseBarterRecordDetail/index.ts +++ b/src/api/wms/purchaseBarterRecordDetail/index.ts @@ -22,6 +22,11 @@ export const getPurchaseBarterRecordDetailPage = async (params) => { } } -export async function exportPurchaseBarterRecord(params: any) { - +export async function exportPurchaseBarterRecord(params) { + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({url: `/wms/purchase-barter-record-detail/export-excel-senior`, data}) + } else { + return await request.download({ url: `/wms/purchase-barter-record-detail/export-excel`, params }) + } } diff --git a/src/api/wms/purchaseBarterRequestMain/index.ts b/src/api/wms/purchaseBarterRequestMain/index.ts index e8fc8e4f4..48454ef15 100644 --- a/src/api/wms/purchaseBarterRequestMain/index.ts +++ b/src/api/wms/purchaseBarterRequestMain/index.ts @@ -47,7 +47,12 @@ export const deletePurchaseBarterRequestMain = async (id: number) => { // 导出采购换货申请主 Excel export const exportPurchaseBarterRequestMain = async (params) => { - return await request.download({ url: `/wms/purchase-barter-request-main/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({url: `/wms/purchase-barter-request-main/export-excel-senior`, data}) + } else { + return await request.download({ url: `/wms/purchase-barter-request-main/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/index.vue b/src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/index.vue index 28d01c6ce..f71f55917 100644 --- a/src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/index.vue +++ b/src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/index.vue @@ -154,6 +154,7 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => if(formField === 'supplierCode'){ setV['supplierCode'] = val[0]['code'] setV['supplierName'] = val[0]['name'] + tableData.value = [] } formRef.setValues(setV) })