import request from '@/utils/request'

// 查询巡检报警记录列表
export function listRecordBusbarAlarm(query) {
  return request({
    url: '/record/recordBusbarAlarm/list',
    method: 'get',
    params: query
  })
}

// 查询巡检报警记录详细
export function getRecordBusbarAlarm(objId) {
  return request({
    url: '/record/recordBusbarAlarm/' + objId,
    method: 'get'
  })
}

// 新增巡检报警记录
export function addRecordBusbarAlarm(data) {
  return request({
    url: '/record/recordBusbarAlarm',
    method: 'post',
    data: data
  })
}

// 修改巡检报警记录
export function updateRecordBusbarAlarm(data) {
  return request({
    url: '/record/recordBusbarAlarm',
    method: 'put',
    data: data
  })
}

// 删除巡检报警记录
export function delRecordBusbarAlarm(objId) {
  return request({
    url: '/record/recordBusbarAlarm/' + objId,
    method: 'delete'
  })
}

// 查询巡检报警记录列表
export function recordBusbarAlarmList(query) {
  return request({
      url: '/record/recordBusbarAlarm/recordBusbarAlarmList',
      method: 'post',
      params: query
    })
}

//记录母排近七天每天一天的巡检记录次数。
export function recordBusbarAlarmCount(data) {
  return request({
    url: '/record/recordBusbarAlarm/recordBusbarAlarmCount',
    method: 'post',
    data: data
  })
}
