diff --git a/src/api/wms/inventorymoveRecordDetail/index.ts b/src/api/wms/inventorymoveRecordDetail/index.ts index 970cce81e..c30051aea 100644 --- a/src/api/wms/inventorymoveRecordDetail/index.ts +++ b/src/api/wms/inventorymoveRecordDetail/index.ts @@ -45,6 +45,16 @@ export const getInventorymoveRecordDetailPage = async (params) => { } } +// 查询库存转移记录子列表 +export const getInventorymoveRecordDetailSettlePage = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/wms/inventorymove-record-detail/seniorSettle', data }) + } else { + return await request.get({ url: `/wms/inventorymove-record-detail/pageSettle`, params }) + } +} // 查询库存转移记录子列表(备件专用) export const getInventorymoveRecordDetailPageSparePart = async (params) => { diff --git a/src/api/wms/inventorymoveRecordMain/index.ts b/src/api/wms/inventorymoveRecordMain/index.ts index 83dc62dd2..5aed8fb7a 100644 --- a/src/api/wms/inventorymoveRecordMain/index.ts +++ b/src/api/wms/inventorymoveRecordMain/index.ts @@ -70,6 +70,17 @@ export const exportInventorymoveRecordMain = async (params) => { } } +// 导出库存转移记录主 Excel +export const exportInventorymoveRecordMainSettle = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.downloadPost({ url: '/wms/inventorymove-record-main/export-excel-senior-settle', data }) + } else { + return await request.download({ url: `/wms/inventorymove-record-main/export-excel-settle`, params }) + } +} + // 导出库存转移记录主 Excel export const exportInventorymoveRecordMainSparePart = async (params) => { diff --git a/src/api/wms/settlementReport/index.ts b/src/api/wms/settlementReport/index.ts index 97da85e57..dcd136d6f 100644 --- a/src/api/wms/settlementReport/index.ts +++ b/src/api/wms/settlementReport/index.ts @@ -38,6 +38,11 @@ export const exportSettlementInfoReportScpPage = async (params) => { return await request.download({ url: `/wms/onlinesettlement-info/export-excel-scp`, params }) } +// 导出发料申请主 Excel +export const exportOnlinesettlementInfoReportExcel = async (params) => { + return await request.download({ url: `/wms/onlinesettlement-info/export-excel-report`, params }) +} + // 查询上线结算配置列表 export const getSettlementReportBalance = async (params) => { // if (params.isSearch) { diff --git a/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts b/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts index 9b8428ddf..958c510b9 100644 --- a/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts +++ b/src/views/wms/deliversettlementManage/deliverplan/saleMain/saleMain.data.ts @@ -872,11 +872,11 @@ export const SaleDetailAndMain = useCrudSchemas(reactive([ } } }, - { - label: '批次', - field: 'batch', - sort: 'custom', - }, + // { + // label: '批次', + // field: 'batch', + // sort: 'custom', + // }, { label: '客户库位', field: 'fromLocationCode', diff --git a/src/views/wms/issueManage/onlinesettlement/settlementReport/index.vue b/src/views/wms/issueManage/onlinesettlement/settlementReport/index.vue index a246ef78e..15ea19a0a 100644 --- a/src/views/wms/issueManage/onlinesettlement/settlementReport/index.vue +++ b/src/views/wms/issueManage/onlinesettlement/settlementReport/index.vue @@ -80,7 +80,9 @@ import * as WarehouseApi from '@/api/wms/warehouse' import * as LocationApi from '@/api/wms/location' import { Location } from '@/views/wms/basicDataManage/factoryModeling/location/location.data' import { tableFormBlurVer, FormBlur, getListByBottonInput } from '@/api/wms/business/inputBlur' - +import { formatDate } from '@/utils/formatTime' +import { usePageLoading } from '@/hooks/web/usePageLoading' +const { loadStart, loadDone } = usePageLoading() // 上线结算配置管理 defineOptions({ name: 'SettlementReport' }) @@ -108,6 +110,7 @@ const { getList, setSearchParams } = tableMethods // 列表头部按钮 const HeadButttondata = [ defaultButtons.defaultFreshBtn(null), // 刷新 + defaultButtons.defaultExportBtn({hasPermi:'wms:onlinesettlement-info:export'}), // 导出 // { // label: '自定义扩展按钮', // name: 'zdy', @@ -123,7 +126,9 @@ const buttonBaseClick = (val, item) => { if (val == 'refresh') { // 刷新 getList() } else if (val == 'filtrate') { // 筛选 - } else { // 其他按钮 + } else if (val == 'export') { // 导出 + handleExport() + }else { // 其他按钮 console.log('其他按钮', item) } } @@ -283,4 +288,19 @@ onMounted(async () => { // importTemplateData.templateUrl = await SettlementConfigurationApi.importTemplate() }) +/** 导出按钮操作 */ +const handleExport = async () => { + try { + // 导出的二次确认 + await message.exportConfirm() + // 发起导出 + loadStart() + const excelTitle = ref(route.meta.title) + const data = await SettlementtReportApi.exportOnlinesettlementInfoReportExcel(tableObject.params) + download.excel(data, `【${excelTitle.value}】【${formatDate(new Date())}】.xlsx`) + } catch { + } finally { + loadDone() + } +} diff --git a/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/productionreturnRequestMain.data.ts b/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/productionreturnRequestMain.data.ts index 826a94322..cb90d72ab 100644 --- a/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/productionreturnRequestMain.data.ts +++ b/src/views/wms/issueManage/productionreturn/productionreturnRequestMain/productionreturnRequestMain.data.ts @@ -1421,7 +1421,8 @@ export const ProductionreturnRequestDetailLabel = useCrudSchemas(reactive @@ -122,9 +122,8 @@ const updataTableColumns = (val) => { } const { tableObject, tableMethods } = useTable({ - getListApi: InventorymoveRecordDetailApi.getInventorymoveRecordDetailPage // 分页接口 + getListApi: InventorymoveRecordDetailApi.getInventorymoveRecordDetailSettlePage // 分页接口 }) -tableObject.params.businessType = 'onlineSettleMove' // 判断 路由名称 进行条件过滤 console.log(146 , fromInventoryStatus.value) @@ -137,7 +136,7 @@ const { getList, setSearchParams } = tableMethods // 列表头部按钮 const HeadButttondata = [ //defaultButtons.defaultAddBtn(null), // 新增 - defaultButtons.defaultExportBtn({hasPermi:`wms:${routeName.value}:export`}), // 导出 + defaultButtons.defaultExportBtn({hasPermi:`wms:onlinesettlement-info:export`}), // 导出 // defaultButtons.defaultImportBtn({hasPermi:`wms:${routeName.value}:import`}), // 导入 defaultButtons.defaultFreshBtn(null), // 刷新 defaultButtons.defaultFilterBtn(null), // 筛选 @@ -296,7 +295,7 @@ const handleExport = async () => { // 发起导出 loadStart() const excelTitle = ref(route.meta.title) - const data = await InventorymoveRecordMainApi.exportInventorymoveRecordMain(tableObject.params) + const data = await InventorymoveRecordMainApi.exportInventorymoveRecordMainSettle(tableObject.params) download.excel(data, `【${excelTitle.value}】【${formatDate(new Date())}】.xlsx`) } catch { } finally { diff --git a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRecordMain/purchasereturnRecordMain.data.ts b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRecordMain/purchasereturnRecordMain.data.ts index f50117219..729013d20 100644 --- a/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRecordMain/purchasereturnRecordMain.data.ts +++ b/src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRecordMain/purchasereturnRecordMain.data.ts @@ -405,15 +405,16 @@ export const PurchasereturnRecordMain = useCrudSchemas( table: { width: 180 }, - isTable: true, - form: { - component: 'DatePicker', - componentProps: { - type: 'datetime', - dateFormat: 'YYYY-MM-DD HH:mm:ss', - valueFormat: 'x' - } - }, + isTable: false, + isForm: false, + // form: { + // component: 'DatePicker', + // componentProps: { + // type: 'datetime', + // dateFormat: 'YYYY-MM-DD HH:mm:ss', + // valueFormat: 'x' + // } + // }, isSearch: true, search: { component: 'DatePicker', @@ -431,7 +432,7 @@ export const PurchasereturnRecordMain = useCrudSchemas( table: { width: 150 }, - isTable: true + isTable: false }, { label: '操作',