From c8d1b5c96bbff097985ea92e68727d0ea54f5e21 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 16 Nov 2023 14:35:07 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AD=96=E7=95=A5=E4=B8=AD=E8=A7=84=E5=88=99?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E3=80=81=E5=8F=82=E6=95=B0=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E3=80=81=E9=85=8D=E7=BD=AE=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/condition/index.ts | 7 ++++++- src/api/wms/configuration/index.ts | 7 ++++++- src/api/wms/configurationsetting/index.ts | 7 ++++++- src/api/wms/paramsetting/index.ts | 7 ++++++- src/api/wms/rule/index.ts | 7 ++++++- .../labelManage/package/index.vue | 16 +++++++++++++--- .../strategySetting/condition/index.vue | 4 ++-- .../strategySetting/configuration/index.vue | 4 ++-- .../configurationsetting/index.vue | 4 ++-- .../strategySetting/paramsetting/index.vue | 4 ++-- .../strategySetting/rule/index.vue | 4 ++-- 11 files changed, 53 insertions(+), 18 deletions(-) diff --git a/src/api/wms/condition/index.ts b/src/api/wms/condition/index.ts index c5654d751..6e2acde9d 100644 --- a/src/api/wms/condition/index.ts +++ b/src/api/wms/condition/index.ts @@ -42,7 +42,12 @@ export const deleteCondition = async (id: number) => { // 导出条件 Excel export const exportCondition = async (params) => { - return await request.download({ url: `/wms/condition/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/condition/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/condition/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/configuration/index.ts b/src/api/wms/configuration/index.ts index 60293c8b5..65fc1adb6 100644 --- a/src/api/wms/configuration/index.ts +++ b/src/api/wms/configuration/index.ts @@ -42,7 +42,12 @@ export const deleteConfiguration = async (id: number) => { // 导出配置 Excel export const exportConfiguration = async (params) => { - return await request.download({ url: `/wms/configuration/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/configuration/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/configuration/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/configurationsetting/index.ts b/src/api/wms/configurationsetting/index.ts index 409831fc8..a1a063cce 100644 --- a/src/api/wms/configurationsetting/index.ts +++ b/src/api/wms/configurationsetting/index.ts @@ -44,7 +44,12 @@ export const deleteConfigurationsetting = async (id: number) => { // 导出配置设置 Excel export const exportConfigurationsetting = async (params) => { - return await request.download({ url: `/wms/configurationsetting/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/configurationsetting/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/configurationsetting/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/paramsetting/index.ts b/src/api/wms/paramsetting/index.ts index 0e8511a7e..c4549f2b1 100644 --- a/src/api/wms/paramsetting/index.ts +++ b/src/api/wms/paramsetting/index.ts @@ -45,7 +45,12 @@ export const deleteParamsetting = async (id: number) => { // 导出参数设置 Excel export const exportParamsetting = async (params) => { - return await request.download({ url: `/wms/paramsetting/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/paramsetting/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/paramsetting/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/api/wms/rule/index.ts b/src/api/wms/rule/index.ts index 8e7a09f09..52b279fa7 100644 --- a/src/api/wms/rule/index.ts +++ b/src/api/wms/rule/index.ts @@ -44,7 +44,12 @@ export const deleteRule = async (id: number) => { // 导出规则 Excel export const exportRule = async (params) => { - return await request.download({ url: `/wms/rule/export-excel`, params }) + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/rule/export-excel-senior`, data }) + } else { + return await request.download({ url: `/wms/rule/export-excel`, params }) + } } // 下载用户导入模板 diff --git a/src/views/wms/basicDataManage/labelManage/package/index.vue b/src/views/wms/basicDataManage/labelManage/package/index.vue index bb5472c22..e61c0cd73 100644 --- a/src/views/wms/basicDataManage/labelManage/package/index.vue +++ b/src/views/wms/basicDataManage/labelManage/package/index.vue @@ -75,11 +75,20 @@ const routeName = ref() routeName.value = route.name const tableColumns = ref(Package.allSchemas.tableColumns) + +/** + * Package2 regularParams = procure采购件标签记录页面 + * Package3 regularParams = manufacture 制造件标签记录页面 + * Package4 regularParams = utensil 器具标签记录页面 + */ +const regularParams = ref(route.name == 'Package2'?'procure':route.name == 'Package3'?'manufacture':route.name == 'Package4'?'utensil':'') + // 字段设置 更新主列表字段 const updataTableColumns = (val) => { tableColumns.value = val } + // 查询列表页面参数设置 const searchTableParams = ref([ //{ @@ -102,7 +111,7 @@ const searchTableSuccess = (formField, searchField, val, basicFormRef, type, row const { tableObject, tableMethods } = useTable({ getListApi: PackageApi.getPackagePage // 分页接口 }) - +tableObject.params.regularParams = regularParams.value // 获得表格的各种操作 const { getList, setSearchParams } = tableMethods @@ -233,7 +242,7 @@ const handleImport = () => { // 导入附件弹窗所需的参数 const importTemplateData = reactive({ templateUrl: '', - templateTitle: '包装导入模版.xls' + templateTitle: '包装导入模版.xlsx' }) // 导入成功之后 @@ -245,7 +254,8 @@ const importSuccess = () => { const searchFormClick = (searchData) => { tableObject.params = { isSearch: true, - filters: searchData.filters + filters: searchData.filters, + regularParams:regularParams.value } getList() // 刷新当前列表 } diff --git a/src/views/wms/basicDataManage/strategySetting/condition/index.vue b/src/views/wms/basicDataManage/strategySetting/condition/index.vue index 28f66eb6a..1e0922afe 100644 --- a/src/views/wms/basicDataManage/strategySetting/condition/index.vue +++ b/src/views/wms/basicDataManage/strategySetting/condition/index.vue @@ -171,8 +171,8 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await ConditionApi.exportCondition(setSearchParams) - download.excel(data, '条件.xls') + const data = await ConditionApi.exportCondition(tableObject.params) + download.excel(data, '条件.xlsx') } catch { } finally { exportLoading.value = false diff --git a/src/views/wms/basicDataManage/strategySetting/configuration/index.vue b/src/views/wms/basicDataManage/strategySetting/configuration/index.vue index 20a20c959..115365f00 100644 --- a/src/views/wms/basicDataManage/strategySetting/configuration/index.vue +++ b/src/views/wms/basicDataManage/strategySetting/configuration/index.vue @@ -171,8 +171,8 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await ConfigurationApi.exportConfiguration(setSearchParams) - download.excel(data, '配置.xls') + const data = await ConfigurationApi.exportConfiguration(tableObject.params) + download.excel(data, '配置.xlsx') } catch { } finally { exportLoading.value = false diff --git a/src/views/wms/basicDataManage/strategySetting/configurationsetting/index.vue b/src/views/wms/basicDataManage/strategySetting/configurationsetting/index.vue index 9066e2d00..31cef0a33 100644 --- a/src/views/wms/basicDataManage/strategySetting/configurationsetting/index.vue +++ b/src/views/wms/basicDataManage/strategySetting/configurationsetting/index.vue @@ -201,8 +201,8 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await ConfigurationsettingApi.exportConfigurationsetting(setSearchParams) - download.excel(data, '配置设置.xls') + const data = await ConfigurationsettingApi.exportConfigurationsetting(tableObject.params) + download.excel(data, '配置设置.xlsx') } catch { } finally { exportLoading.value = false diff --git a/src/views/wms/basicDataManage/strategySetting/paramsetting/index.vue b/src/views/wms/basicDataManage/strategySetting/paramsetting/index.vue index a098fae59..7eb12a2ea 100644 --- a/src/views/wms/basicDataManage/strategySetting/paramsetting/index.vue +++ b/src/views/wms/basicDataManage/strategySetting/paramsetting/index.vue @@ -172,8 +172,8 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await ParamsettingApi.exportParamsetting(setSearchParams) - download.excel(data, '参数设置.xls') + const data = await ParamsettingApi.exportParamsetting(tableObject.params) + download.excel(data, '参数设置.xlsx') } catch { } finally { exportLoading.value = false diff --git a/src/views/wms/basicDataManage/strategySetting/rule/index.vue b/src/views/wms/basicDataManage/strategySetting/rule/index.vue index 82a6140e3..53fb8fc94 100644 --- a/src/views/wms/basicDataManage/strategySetting/rule/index.vue +++ b/src/views/wms/basicDataManage/strategySetting/rule/index.vue @@ -200,8 +200,8 @@ const handleExport = async () => { await message.exportConfirm() // 发起导出 exportLoading.value = true - const data = await RuleApi.exportRule(setSearchParams) - download.excel(data, '规则.xls') + const data = await RuleApi.exportRule(tableObject.params) + download.excel(data, '规则.xlsx') } catch { } finally { exportLoading.value = false