import request from '@/utils/request'
//标准规范
export function getStandardList(query) {
  return request({
    url: '/qm/standard/',
    method: 'get',
    params: query
  })
}
export function createStandard(data) {
  return request({
    url: '/qm/standard/',
    method: 'post',
    data
  })
}
export function updateStandard(id, data) {
  return request({
    url: `/qm/standard/${id}/`,
    method: 'put',
    data
  })
}
export function deleteStandard(id, data) {
  return request({
    url: `/qm/standard/${id}/`,
    method: 'delete',
    data
  })
}
//检测项目
export function getTestitemList(query) {
  return request({
    url: '/qm/testitem/',
    method: 'get',
    params: query
  })
}
export function createTestitem(data) {
  return request({
    url: '/qm/testitem/',
    method: 'post',
    data
  })
}
export function updateTestitem(id, data) {
  return request({
    url: `/qm/testitem/${id}/`,
    method: 'put',
    data
  })
}
export function deleteTestitem(id, data) {
  return request({
    url: `/qm/testitem/${id}/`,
    method: 'delete',
    data
  })
}

