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.

180 lines
6.2 KiB

1 year ago
import request from '@/config/axios'
export interface PurchasereceiptRequestMainVO {
asnNumber: string
ppNumber: string
supplierCode: string
carrierCode: string
transferMode: string
fromWarehouseCode: string
toWarehouseCode: string
fromAreaTypes: string
toAreaTypes: string
fromAreaCodes: string
toAreaCodes: string
toDockCode: string
number: string
businessType: string
remark: string
createTime: Date
creator: string
requestTime: Date
dueTime: Date
departmentCode: string
updateTime: Date
updater: string
status: string
autoCommit: string
autoAgree: string
autoExecute: string
directCreateRecord: string
vehiclePlateNumber: string
}
// 查询采购收货申请主列表
export const getPurchasereceiptRequestMainPage = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
return await request.post({ url: '/wms/purchasereceipt-request-main/senior', data })
} else {
return await request.get({ url: `/wms/purchasereceipt-request-main/page`, params })
}
}
// 查询备件收货申请主列表
export const getPurchasereceiptRequestMainPageSpare = async (params) => {
if (params.isSearch) {
delete params.isSearch
const data = {...params}
return await request.post({ url: '/wms/purchasereceipt-request-main/seniorSpare', data })
} else {
return await request.get({ url: `/wms/purchasereceipt-request-main/pageSpare`, params })
}
}
// 查询采购收货申请主详情
export const getPurchasereceiptRequestMain = async (id: number) => {
return await request.get({ url: `/wms/purchasereceipt-request-main/get?id=` + id })
}
// 新增采购收货申请主
export const createPurchasereceiptRequestMain = async (data: PurchasereceiptRequestMainVO) => {
return await request.post({ url: `/wms/purchasereceipt-request-main/create`, data })
}
// 新增备件收货申请主
export const createPurchasereceiptRequestMainSpare = async (data: PurchasereceiptRequestMainVO) => {
return await request.post({ url: `/wms/purchasereceipt-request-main/createSpare`, data })
}
// 修改采购收货申请主
export const updatePurchasereceiptRequestMain = async (data: PurchasereceiptRequestMainVO) => {
return await request.put({ url: `/wms/purchasereceipt-request-main/update`, data })
}
// 删除采购收货申请主
export const deletePurchasereceiptRequestMain = async (id: number) => {
return await request.delete({ url: `/wms/purchasereceipt-request-main/delete?id=` + id })
}
// 导出采购收货申请主 Excel
export const exportPurchasereceiptRequestMain = async (params) => {
if (params.isSearch) {
const data = {...params}
return await request.downloadPost({ url: `/wms/purchasereceipt-request-main/export-excel-senior`, data })
} else {
return await request.download({ url: `/wms/purchasereceipt-request-main/export-excel`, params })
}
}
5 months ago
// 导出协定品收货申请主 Excel
5 months ago
export const exportToolPurchasereceiptRequestMain = async (params) => {
if (params.isSearch) {
params.source_type = "TOOL"
const data = {...params}
return await request.downloadPost({ url: `/wms/purchasereceipt-request-main/export-excel-senior`, data })
} else {
params.sourceType = "TOOL"
5 months ago
return await request.download({ url: `/wms/purchasereceipt-request-main/export-excel`, params })
}
}
// 导出号试品收货申请主 Excel
export const exportDevelopPurchasereceiptRequestMain = async (params) => {
if (params.isSearch) {
params.source_type = "Develop"
const data = {...params}
return await request.downloadPost({ url: `/wms/purchasereceipt-request-main/export-excel-senior`, data })
} else {
params.sourceType = "Develop"
5 months ago
return await request.download({ url: `/wms/purchasereceipt-request-main/export-excel`, params })
}
}
// 导出采购M型收货申请主 Excel
export const exportPurchasereceiptRequestMainOrderTypeM = async (params) => {
if (params.isSearch) {
const data = {...params}
return await request.downloadPost({ url: `/wms/purchasereceipt-request-main/export-excel-senior-orderTypeM`, data })
} else {
return await request.download({ url: `/wms/purchasereceipt-request-main/export-excel-orderTypeM`, params })
}
}
10 months ago
// 导出备件收货申请
export const exportSparereceiptRequestMain = async (params) => {
if (params.isSearch) {
const data = {...params}
return await request.downloadPost({ url: `/wms/purchasereceipt-request-main/export-excel-spare-senior`, data })
} else {
return await request.download({ url: `/wms/purchasereceipt-request-main/export-excel-spare`, params })
}
}
1 year ago
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/purchasereceipt-request-main/get-import-template' })
}
// 关闭采购收货申请主 Excel
export const closePurchasereceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/purchasereceipt-request-main/close?id=` + id })
}
// 重新添加采购收货申请主 Excel
export const reAddPurchasereceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/purchasereceipt-request-main/reAdd?id=` + id })
}
// 提交采购收货申请主 Excel
export const submitPurchasereceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/purchasereceipt-request-main/submit?id=` + id })
}
// 审批通过采购收货申请主 Excel
export const agreePurchasereceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/purchasereceipt-request-main/agree?id=` + id })
}
// 审批驳回采购收货申请主 Excel
export const refusedPurchasereceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/purchasereceipt-request-main/refused?id=` + id })
}
// 处理采购收货申请主 Excel
export const handlePurchasereceiptRequestMain = async (id) => {
return await request.put({ url: `/wms/purchasereceipt-request-main/handle?id=` + id })
}
// 生成标签
export const genLabel = async (data) => {
return await request.post({ url: `/wms/purchasereceipt-request-main/genLabel`, data })
1 year ago
}
// “到库位代码”默认为待检库
export const queryPurchasePlan = async (data) => {
return await request.post({ url: `/wms/purchasereceipt-request-main/queryPurchasePlan`, data })
}