import request from '@/utils/request'

//机具类型管理列表信息
export function getListDevice(query) {
  return request({
      url: '/material/ma_machine/list',
      method: 'get',
      params: query,
  })
}

//查看机具类型管理列表详细信息
export function getDeviceDetail(id) {
  return request({
      url: '/material/ma_machine/'+ id,
      method: 'get',
  })
}


// 物资名称下拉框-
export function getDeviceType(query) {
  return request({
    url: '/material/ma_machine/getTypeList',
    method: 'get',
    params: query
  })
}

// 仓库管理--删除
export function delDevice(id) {
  return request({
      url: '/material/ma_machine/' + id,
      method: 'delete',
  })
}

// 仓库管理--修改
export function editDevice(data) {
  return request({
      url: '/material/ma_machine',
      method: 'put',
      data: data,
  })
}

// 仓库管理--新增
export function addDevice(data) {
  return request({
      url: '/material/ma_machine',
      method: 'post',
      data: data,
  })
}

// 工程项目-列表
export function getProjectList(query) {
  return request({
    url: '/material/base/bmProjectInfo/projectInfoAll',
    method: 'get',
    params: query
  })
}

