diff --git a/src/api/wms/customerStatementDetail/index.ts b/src/api/wms/customerStatementDetail/index.ts index 0c4729f6d..c1bb2837c 100644 --- a/src/api/wms/customerStatementDetail/index.ts +++ b/src/api/wms/customerStatementDetail/index.ts @@ -35,7 +35,7 @@ export interface CustomerStatementDetailVO { concurrencyStamp: string } -// 查询客户对账单子信息表(WMS)列表 +// 查询客户对账单子信息明细表(WMS)列表或者查询客户对账单对账差异列表 二者共用一个 export const getCustomerStatementDetailPage = async (params) => { if (params.isSearch) { delete params.isSearch @@ -66,12 +66,27 @@ export const deleteCustomerStatementDetail = async (id: number) => { return await request.delete({ url: `/wms/customer-statement-detail/delete?id=` + id }) } -// 导出客户对账单子信息表(WMS) Excel -export const exportCustomerStatementDetail = async (params) => { - return await request.download({ url: `/wms/customer-statement-detail/export-excel`, params }) -} - // 下载用户导入模板 export const importTemplate = () => { return request.download({ url: '/wms/customer-statement-detail/get-import-template' }) +} + +//导出明细数据需要传masterId +export const exportCustomerStatementDetail = async (params) => { + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/customer-statement-detail/export-excel-senior`, data }) + }else{ + return await request.download({ url: `/wms/customer-statement-detail/export-excel`, params }) + } +} + +//导出详情对账差异列表数据 需要传masterId +export const exportCustomerStatementCompareDetail = async (params) => { + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/customer-statement-detail/export-excel-compare-senior`, data }) + }else{ + return await request.download({ url: `/wms/customer-statement-detail/export-excel-compare`, params }) + } } \ No newline at end of file diff --git a/src/api/wms/customerStatementMain/index.ts b/src/api/wms/customerStatementMain/index.ts index 1b7d899cb..9c8cb0396 100644 --- a/src/api/wms/customerStatementMain/index.ts +++ b/src/api/wms/customerStatementMain/index.ts @@ -52,11 +52,6 @@ export const deleteCustomerStatementMain = async (id: number) => { return await request.delete({ url: `/wms/customer-statement-main/delete?id=` + id }) } -// 导出客户对账单主信息表(WMS) Excel -export const exportCustomerStatementMain = async (params) => { - return await request.download({ url: `/wms/customer-statement-main/export-excel`, params }) -} - // 下载客户对账单导入模板 export const importTemplate = () => { return request.download({ url: '/wms/customer-statement-main/get-import-template' }) @@ -88,11 +83,53 @@ export const sendBack = async (id: number) => { } // 导入客户模具分摊对账单前校验该客户对账单下是否存在已分摊的模具分摊对账单如果有提示 -export const verifyDataExistShare = async (customerId:number) => { +export const verifyDataExistShare = async (customerId:number) => {//customerId为客户对账单id return await request.get({ url: `/wms/customer-tool-apport-statement-detail/verifyDataExist?customerId=` + customerId }) } // 下载客户模具分摊对账单导入模板 export const importShareTemplate = () => { return request.download({ url: '/wms/customer-tool-apport-statement-detail/get-import-template' }) -} \ No newline at end of file +} + +// 客户对账单点击发布接口 +export const publish = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-main/publish?id=` + id}) +} + +// 根据对账单主id点击确认分摊 +export const confirmationShare = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-main/confirmationShare?id=` + id}) +} + +// 客户对账单查询客户代码 +export const getCustomerList = async () => { + return await request.get({ url: `/wms/customer-statement-main/confirmationShare`}) +} + + +// 客户模具分摊对账单修改调整金额 +export const updateAdjustmentAmount = async (id:number,masterId:number,amount:number) => { + return await request.get({ url: `/wms/customer-statement-main/updateAdjustmentAmount?id=` + id+'&masterId='+masterId+'&amount='+amount}) +} + +// 导出客户对账单Excel +export const exportCustomerStatementMain = async (params) => { + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/eam/basic-eam-workshop/export-excel-senior`, data }) + }else{ + return await request.download({ url: `/wms/customer-statement-main/export-excel`, params }) + } +} + +// 导出客户模具分摊对账单Excel 需要传masterId +export const exportCustomerStatementShareMain = async (params) => { + if (params.isSearch) { + const data = {...params} + return await request.downloadPost({ url: `/wms/customer-tool-apport-statement-detail/export-excel-senior`, data }) + }else{ + return await request.download({ url: `/wms/customer-tool-apport-statement-detail/export-excel`, params }) + } +} +