import request from '@/utils/request'

// 查询厂商信息列表
export function listManufacturer(query) {
  return request({
    url: '/api/manufacturer/list',
    method: 'get',
    params: query
  })
}

// 查询厂商信息详细
export function getManufacturer(id) {
  return request({
    url: '/api/manufacturer/' + id,
    method: 'get'
  })
}

// 新增厂商信息
export function addManufacturer(data) {
  return request({
    url: '/api/manufacturer',
    method: 'post',
    data: data
  })
}

// 修改厂商信息
export function updateManufacturer(data) {
  return request({
    url: '/api/manufacturer',
    method: 'put',
    data: data
  })
}

// 删除厂商信息
export function delManufacturer(id) {
  return request({
    url: '/api/manufacturer/' + id,
    method: 'delete'
  })
}
