diff --git a/src/api/wms/productreceiptRecordMain/index.ts b/src/api/wms/productreceiptRecordMain/index.ts index 0fe298f8c..5bf690773 100644 --- a/src/api/wms/productreceiptRecordMain/index.ts +++ b/src/api/wms/productreceiptRecordMain/index.ts @@ -86,14 +86,14 @@ export const deleteProductreceiptRecordMain = async (id: number) => { // 导出制品收货记录主 Excel export const exportProductreceiptRecordMain = async (params) => { - params.type = 'predict' + // params.type = 'predict' if (params.isSearch) { - const cmd = { - 'column':'type', - 'action':'==', - 'value':'predict' - } - params.filters.push(cmd) + // const cmd = { + // 'column':'type', + // 'action':'==', + // 'value':'predict' + // } + // params.filters.push(cmd) delete params.isSearch const data = {...params} return await request.downloadPost({ url: '/wms/productreceipt-record-main/export-excel-senior', data }) diff --git a/src/views/wms/productionManage/productreceipt/productreceiptRecordMain/index.vue b/src/views/wms/productionManage/productreceipt/productreceiptRecordMain/index.vue index f6eafc52b..b6a9a54b5 100644 --- a/src/views/wms/productionManage/productreceipt/productreceiptRecordMain/index.vue +++ b/src/views/wms/productionManage/productreceipt/productreceiptRecordMain/index.vue @@ -339,6 +339,19 @@ const handleExport = async () => { // 发起导出 loadStart() const excelTitle = ref(route.meta.title) + debugger + tableObject.params.type = 'predict' + if (tableObject.params.isSearch){ + const cmd = { + 'column':'type', + 'action':'==', + 'value':'predict' + } + if (!Array.isArray(tableObject.params.filters)) { + tableObject.params.filters = []; + } + tableObject.params.filters.push(cmd) + } const data = await ProductreceiptRecordMainApi.exportProductreceiptRecordMain(tableObject.params) download.excel(data, `【${excelTitle.value}】【${formatDate(new Date())}】.xlsx`) } catch { diff --git a/src/views/wms/productionManage/productreceiptscrap/productreceiptscrapRecordMain/index.vue b/src/views/wms/productionManage/productreceiptscrap/productreceiptscrapRecordMain/index.vue index be0ca8bfa..870d2c51f 100644 --- a/src/views/wms/productionManage/productreceiptscrap/productreceiptscrapRecordMain/index.vue +++ b/src/views/wms/productionManage/productreceiptscrap/productreceiptscrapRecordMain/index.vue @@ -201,6 +201,18 @@ const handleExport = async () => { // 发起导出 loadStart() const excelTitle = ref(route.meta.title) + tableObject.params.type = 'scrap' + if (tableObject.params.isSearch){ + const cmd = { + 'column':'type', + 'action':'==', + 'value':'scrap' + } + if (!Array.isArray(tableObject.params.filters)) { + tableObject.params.filters = []; + } + tableObject.params.filters.push(cmd) + } const data = await ProductreceiptRecordMainApi.exportProductreceiptRecordMain(tableObject.params) download.excel(data, `【${excelTitle.value}】【${formatDate(new Date())}】.xlsx`) } catch {