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.
53 lines
1.5 KiB
53 lines
1.5 KiB
import request from '@/config/axios'
|
|
|
|
export interface SamplingProcessVO {
|
|
id: number
|
|
code: string
|
|
describe: string
|
|
sampleType: string
|
|
evaluationMode: string
|
|
sampleSize: number
|
|
sampleProgCode: number
|
|
available: string
|
|
}
|
|
|
|
// 查询采样过程列表
|
|
export const getSamplingProcessPage = async (params) => {
|
|
if (params.isSearch) {
|
|
delete params.isSearch
|
|
const data = {...params}
|
|
return await request.post({ url: '/qms/sampling-process/senior', data })
|
|
} else {
|
|
return await request.get({ url: `/qms/sampling-process/page`, params })
|
|
}
|
|
}
|
|
|
|
// 查询采样过程详情
|
|
export const getSamplingProcess = async (id: number) => {
|
|
return await request.get({ url: `/qms/sampling-process/get?id=` + id })
|
|
}
|
|
|
|
// 新增采样过程
|
|
export const createSamplingProcess = async (data: SamplingProcessVO) => {
|
|
return await request.post({ url: `/qms/sampling-process/create`, data })
|
|
}
|
|
|
|
// 修改采样过程
|
|
export const updateSamplingProcess = async (data: SamplingProcessVO) => {
|
|
return await request.put({ url: `/qms/sampling-process/update`, data })
|
|
}
|
|
|
|
// 删除采样过程
|
|
export const deleteSamplingProcess = async (id: number) => {
|
|
return await request.delete({ url: `/qms/sampling-process/delete?id=` + id })
|
|
}
|
|
|
|
// 导出采样过程 Excel
|
|
export const exportSamplingProcess = async (params) => {
|
|
return await request.download({ url: `/qms/sampling-process/export-excel`, params })
|
|
}
|
|
|
|
// 下载用户导入模板
|
|
export const importTemplate = () => {
|
|
return request.download({ url: '/qms/sampling-process/get-import-template' })
|
|
}
|