From 11d9b43881aa78401de142d74c651eac2d36b448 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Wed, 15 Nov 2023 19:10:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=A5=E5=8E=82=E5=BB=BA=E6=A8=A1=E5=AF=BC?= =?UTF-8?q?=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/areabasic/index.ts | 7 ++++++- src/api/wms/dock/index.ts | 7 ++++++- src/api/wms/enterprise/index.ts | 7 ++++++- src/api/wms/location/index.ts | 8 +++++++- src/api/wms/locationgroup/index.ts | 7 ++++++- src/api/wms/process/index.ts | 7 ++++++- src/api/wms/productionline/index.ts | 7 ++++++- src/api/wms/warehouse/index.ts | 7 ++++++- src/api/wms/workshop/index.ts | 7 ++++++- src/api/wms/workstation/index.ts | 7 ++++++- .../basicDataManage/factoryModeling/areabasic/index.vue | 2 +- .../wms/basicDataManage/factoryModeling/dock/index.vue | 2 +- .../basicDataManage/factoryModeling/enterprise/index.vue | 2 +- .../basicDataManage/factoryModeling/location/index.vue | 2 +- .../factoryModeling/locationgroup/index.vue | 2 +- .../wms/basicDataManage/factoryModeling/process/index.vue | 2 +- .../factoryModeling/productionline/index.vue | 2 +- .../basicDataManage/factoryModeling/warehouse/index.vue | 2 +- .../basicDataManage/factoryModeling/workshop/index.vue | 2 +- .../basicDataManage/factoryModeling/workstation/index.vue | 2 +- 20 files changed, 71 insertions(+), 20 deletions(-) diff --git a/src/api/wms/areabasic/index.ts b/src/api/wms/areabasic/index.ts index 2d689039b..b0e97fffb 100644 --- a/src/api/wms/areabasic/index.ts +++ b/src/api/wms/areabasic/index.ts @@ -49,7 +49,12 @@ export const deleteArea = async (id: number) => { // 导出库区 Excel export const exportArea = async (params) => { - return await request.download({ url: `/wms/areabasic/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/areabasic/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/areabasic/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/dock/index.ts b/src/api/wms/dock/index.ts index d6335273f..ece07e8e2 100644 --- a/src/api/wms/dock/index.ts +++ b/src/api/wms/dock/index.ts @@ -53,7 +53,12 @@ export const deleteDock = async (id: number) => { // 导出月台 Excel export const exportDock = async (params) => { - return await request.download({ url: `/wms/dock/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/dock/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/dock/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/enterprise/index.ts b/src/api/wms/enterprise/index.ts index f9fa8ebd2..87cf0ff26 100644 --- a/src/api/wms/enterprise/index.ts +++ b/src/api/wms/enterprise/index.ts @@ -50,7 +50,12 @@ export const deleteEnterprise = async (id: number) => { // 导出企业 Excel export const exportEnterprise = async (params) => { - return await request.download({ url: `/wms/enterprise/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/enterprise/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/enterprise/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/location/index.ts b/src/api/wms/location/index.ts index a827647f3..f7d2e19d8 100644 --- a/src/api/wms/location/index.ts +++ b/src/api/wms/location/index.ts @@ -61,7 +61,13 @@ export const deleteLocation = async (id: number) => { // 导出库位 Excel export const exportLocation = async (params) => { - return await request.download({ url: `/wms/location/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/location/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/location/export-excel`, params }) + } + } // 下载用户导入模板 diff --git a/src/api/wms/locationgroup/index.ts b/src/api/wms/locationgroup/index.ts index 874caddfc..3aa976b9c 100644 --- a/src/api/wms/locationgroup/index.ts +++ b/src/api/wms/locationgroup/index.ts @@ -49,7 +49,12 @@ export const deleteLocationgroup = async (id: number) => { // 导出库位组 Excel export const exportLocationgroup = async (params) => { - return await request.download({ url: `/wms/locationgroup/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/locationgroup/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/locationgroup/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/process/index.ts b/src/api/wms/process/index.ts index ac47d8ebd..c89f7e192 100644 --- a/src/api/wms/process/index.ts +++ b/src/api/wms/process/index.ts @@ -46,7 +46,12 @@ export const deleteProcess = async (id: number) => { // 导出工序 Excel export const exportProcess = async (params) => { - return await request.download({ url: `/wms/process/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/process/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/process/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/productionline/index.ts b/src/api/wms/productionline/index.ts index afbab3608..050c8a0fb 100644 --- a/src/api/wms/productionline/index.ts +++ b/src/api/wms/productionline/index.ts @@ -47,7 +47,12 @@ export const deleteProductionline = async (id: number) => { // 导出生产线 Excel export const exportProductionline = async (params) => { - return await request.download({ url: `/wms/productionline/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/productionline/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/productionline/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/warehouse/index.ts b/src/api/wms/warehouse/index.ts index 169e1986d..882fac24e 100644 --- a/src/api/wms/warehouse/index.ts +++ b/src/api/wms/warehouse/index.ts @@ -47,7 +47,12 @@ export const deleteWarehouse = async (id: number) => { // 导出仓库 Excel export const exportWarehouse = async (params) => { - return await request.download({ url: `/wms/warehouse/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/warehouse/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/warehouse/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/workshop/index.ts b/src/api/wms/workshop/index.ts index a07fb72c8..727253443 100644 --- a/src/api/wms/workshop/index.ts +++ b/src/api/wms/workshop/index.ts @@ -44,7 +44,12 @@ export const deleteWorkshop = async (id: number) => { // 导出车间 Excel export const exportWorkshop = async (params) => { - return await request.download({ url: `/wms/workshop/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/workshop/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/workshop/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/workstation/index.ts b/src/api/wms/workstation/index.ts index 5314bd581..40e5dd648 100644 --- a/src/api/wms/workstation/index.ts +++ b/src/api/wms/workstation/index.ts @@ -48,7 +48,12 @@ export const deleteWorkstation = async (id: number) => { // 导出工位 Excel export const exportWorkstation = async (params) => { - return await request.download({ url: `/wms/workstation/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/workstation/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/workstation/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/views/wms/basicDataManage/factoryModeling/areabasic/index.vue b/src/views/wms/basicDataManage/factoryModeling/areabasic/index.vue index 3bc1ac6bc..568ce196c 100644 --- a/src/views/wms/basicDataManage/factoryModeling/areabasic/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/areabasic/index.vue @@ -205,7 +205,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await AreaApi.exportArea(setSearchParams) + const data = await AreaApi.exportArea(tableObject.params) download.excel(data, '库区.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/dock/index.vue b/src/views/wms/basicDataManage/factoryModeling/dock/index.vue index a411e6025..daa1a76e4 100644 --- a/src/views/wms/basicDataManage/factoryModeling/dock/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/dock/index.vue @@ -205,7 +205,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await DockApi.exportDock(setSearchParams) + const data = await DockApi.exportDock(tableObject.params) download.excel(data, '月台.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/enterprise/index.vue b/src/views/wms/basicDataManage/factoryModeling/enterprise/index.vue index c4bdc535b..6972159e9 100644 --- a/src/views/wms/basicDataManage/factoryModeling/enterprise/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/enterprise/index.vue @@ -175,7 +175,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await EnterpriseApi.exportEnterprise(setSearchParams) + const data = await EnterpriseApi.exportEnterprise(tableObject.params) download.excel(data, '企业.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/location/index.vue b/src/views/wms/basicDataManage/factoryModeling/location/index.vue index 90f4f44ca..656c01228 100644 --- a/src/views/wms/basicDataManage/factoryModeling/location/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/location/index.vue @@ -205,7 +205,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await LocationApi.exportLocation(setSearchParams) + const data = await LocationApi.exportLocation(tableObject.params) download.excel(data, '库位.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/locationgroup/index.vue b/src/views/wms/basicDataManage/factoryModeling/locationgroup/index.vue index 856972377..ac0779dfc 100644 --- a/src/views/wms/basicDataManage/factoryModeling/locationgroup/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/locationgroup/index.vue @@ -205,7 +205,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await LocationgroupApi.exportLocationgroup(setSearchParams) + const data = await LocationgroupApi.exportLocationgroup(tableObject.params) download.excel(data, '库位组.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/process/index.vue b/src/views/wms/basicDataManage/factoryModeling/process/index.vue index ac8f74c37..bc23ab2ca 100644 --- a/src/views/wms/basicDataManage/factoryModeling/process/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/process/index.vue @@ -205,7 +205,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await ProcessApi.exportProcess(setSearchParams) + const data = await ProcessApi.exportProcess(tableObject.params) download.excel(data, '工序.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/productionline/index.vue b/src/views/wms/basicDataManage/factoryModeling/productionline/index.vue index 4cb299b47..4c9ad6929 100644 --- a/src/views/wms/basicDataManage/factoryModeling/productionline/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/productionline/index.vue @@ -205,7 +205,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await ProductionlineApi.exportProductionline(setSearchParams) + const data = await ProductionlineApi.exportProductionline(tableObject.params) download.excel(data, '生产线.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/warehouse/index.vue b/src/views/wms/basicDataManage/factoryModeling/warehouse/index.vue index b45cdb6a3..0b85e6f28 100644 --- a/src/views/wms/basicDataManage/factoryModeling/warehouse/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/warehouse/index.vue @@ -195,7 +195,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await WarehouseApi.exportWarehouse(setSearchParams) + const data = await WarehouseApi.exportWarehouse(tableObject.params) download.excel(data, '仓库.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/workshop/index.vue b/src/views/wms/basicDataManage/factoryModeling/workshop/index.vue index 4238ddc94..3627127d5 100644 --- a/src/views/wms/basicDataManage/factoryModeling/workshop/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/workshop/index.vue @@ -195,7 +195,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await WorkshopApi.exportWorkshop(setSearchParams) + const data = await WorkshopApi.exportWorkshop(tableObject.params) download.excel(data, '车间.xls') } catch { } finally { diff --git a/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue b/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue index 8425e8987..b828ce41d 100644 --- a/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue +++ b/src/views/wms/basicDataManage/factoryModeling/workstation/index.vue @@ -205,7 +205,7 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await WorkstationApi.exportWorkstation(setSearchParams) + const data = await WorkstationApi.exportWorkstation(tableObject.params) download.excel(data, '工位.xls') } catch { } finally {