diff --git a/src/api/mes/zjproductrecord/index.ts b/src/api/mes/zjproductrecord/index.ts new file mode 100644 index 00000000..5a848b37 --- /dev/null +++ b/src/api/mes/zjproductrecord/index.ts @@ -0,0 +1,52 @@ +import request from '@/config/axios' + +// 试产质检记录 VO +export interface ZjProductRecordVO { + id: number // ID + type: string // 工序 + name: string // 名称 + unit: string // 单位 + upperVal: number // 上限值 + lowerVal: number // 下限值 + productId: number // 关联产品id + remark: string // 备注 + planId: number // 关联计划id +} + +// 试产质检记录 API +export const ZjProductRecordApi = { + // 查询试产质检记录分页 + getZjProductRecordPage: async (params: any) => { + return await request.get({ url: `/mes/zj-product-record/page`, params }) + }, + + // 查询试产质检记录详情 + getZjProductRecord: async (id: number) => { + return await request.get({ url: `/mes/zj-product-record/get?id=` + id }) + }, + + // 新增试产质检记录 + createZjProductRecord: async (data: ZjProductRecordVO) => { + return await request.post({ url: `/mes/zj-product-record/create`, data }) + }, + + // 修改试产质检记录 + updateZjProductRecord: async (data: ZjProductRecordVO) => { + return await request.put({ url: `/mes/zj-product-record/update`, data }) + }, + // 批量修改试产质检记录 + updateZjProductRecordBatch: async (data: ZjProductRecordVO[]) => { + return await request.put({ url: `/mes/zj-product-record/updateBatch`, data }) + }, + + + // 删除试产质检记录 + deleteZjProductRecord: async (id: number) => { + return await request.delete({ url: `/mes/zj-product-record/delete?id=` + id }) + }, + + // 导出试产质检记录 Excel + exportZjProductRecord: async (params) => { + return await request.download({ url: `/mes/zj-product-record/export-excel`, params }) + } +} \ No newline at end of file