You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

67 lines
2.9 KiB

import request from '@/config/axios'
export interface CustomerToolApportStatementForecastMainVO {
id: number
number: string
customerCode: string
customerName: string
yearsMonth: Date
remark: string
available: string
}
// 查询客户模具分摊对账单预测主表(WMS)列表
export const getCustomerToolApportStatementForecastMainPage = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
return await request.post({ url: '/wms/customer-tool-apport-statement-forecast-main/senior', data })
} else {
return await request.get({ url: `/wms/customer-tool-apport-statement-forecast-main/page`, params })
}
}
// 查询客户模具分摊对账单预测主表(WMS)详情
export const getCustomerToolApportStatementForecastMain = async (id: number) => {
return await request.get({ url: `/wms/customer-tool-apport-statement-forecast-main/get?id=` + id })
}
// 新增客户模具分摊对账单预测主表(WMS)
export const createCustomerToolApportStatementForecastMain = async (data: CustomerToolApportStatementForecastMainVO) => {
return await request.post({ url: `/wms/customer-tool-apport-statement-forecast-main/create`, data })
}
// 修改客户模具分摊对账单预测主表(WMS)
export const updateCustomerToolApportStatementForecastMain = async (data: CustomerToolApportStatementForecastMainVO) => {
return await request.put({ url: `/wms/customer-tool-apport-statement-forecast-main/update`, data })
}
// 删除客户模具分摊对账单预测主表(WMS)
export const deleteCustomerToolApportStatementForecastMain = async (id: number) => {
return await request.delete({ url: `/wms/customer-tool-apport-statement-forecast-main/delete?id=` + id })
}
// 导出客户模具分摊对账单预测主表(WMS) Excel
export const exportCustomerToolApportStatementForecastMain = async (params) => {
if (params.isSearch) {
const data = {...params}
return await request.downloadPost({ url: `/wms/customer-tool-apport-statement-forecast-main/export-excel-senior`, data })
}else{
return await request.download({ url: `/wms/customer-tool-apport-statement-forecast-main/export-excel`, params })
}
}
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/customer-tool-apport-statement-forecast-main/get-import-template' })
}
// 导入客户对账单前校验是否有相同客户代码和年月的数据存在
export const verifyDataExist = async (yearsMonthStr: String,customerCode:String) => {
return await request.get({ url: `/wms/customer-tool-apport-statement-forecast-main/verifyDataExist?yearsMonthStr=` + yearsMonthStr+'&customerCode='+customerCode })
}
// 客户对账单重新比对
export const recontrast = async (id: number) => {
return await request.get({ url: `/wms/customer-tool-apport-statement-forecast-main/recontrast?id=` + id})
}