import request from '@/utils/request'

// 查询维修站点-车间列表
export function listWorkshop(query) {
  return request({
    url: '/business/workshop/list',
    method: 'get',
    params: query
  })
}

// 查询维修站点-车间详细
export function getWorkshop(id) {
  return request({
    url: '/business/workshop/' + id,
    method: 'get'
  })
}

// 新增维修站点-车间
export function addWorkshop(data) {
  return request({
    url: '/business/workshop',
    method: 'post',
    data: data
  })
}

// 修改维修站点-车间
export function updateWorkshop(data) {
  return request({
    url: '/business/workshop',
    method: 'put',
    data: data
  })
}

// 删除维修站点-车间
export function delWorkshop(id) {
  return request({
    url: '/business/workshop/' + id,
    method: 'delete'
  })
}
