import request from '@/utils/request'

// 设备产品数据库列表
export function getEquipmentDataList(data) {
  return request({
    url: `device/origin/list?pageSize=${data.pageSize}&pageNum=${data.pageNum}`,
    method: 'post',
    data: data
  })
}
// 设备产品数据库模板下载
export function downLoadMb(data) {
  return request({
    url: `device/origin/download`,
    method: 'post',
    data: data,
    responseType: 'blob'
  })
}
// 设备产品数据库新增
export function addEquipment(data) {
  return request({
    url: `/device/origin`,
    method: 'post',
    data: data
  })
}
// 设备产品数据库新增
export function editEquipment(data) {
  return request({
    url: `/device/origin`,
    method: 'put',
    data: data
  })
}
// 设备产品数据库详情
export function getEquipmentDetail(id) {
  return request({
    url: `/device/origin/${id}`,
    method: 'get',
  })
}
// 设备产品数据库删除
export function deleteEquipments(data) {
  return request({
    url: `/device/origin/delete`,
    method: 'post',
    data: data
  })
}
// 设备产品数据库导出
export function exportEquipments(data) {
  return request({
    url: `/device/origin/export`,
    method: 'post',
    data: data,
    responseType: 'blob'
  })
}