import request from '@/utils/request'

// 查询盲板列表
export function listBlind(query) {
  return request({
    url: '/pssr/blind/list',
    method: 'get',
    params: query
  })
}

// 查询盲板详细
export function getBlind(id) {
  return request({
    url: '/pssr/blind/' + id,
    method: 'get'
  })
}

// 新增盲板
export function addBlind(data) {
  return request({
    url: '/pssr/blind',
    method: 'post',
    data: data
  })
}

// 修改盲板
export function updateBlind(data) {
  return request({
    url: '/pssr/blind',
    method: 'put',
    data: data
  })
}

//
export function updateBlindBatch(data) {
  return request({
    url: '/pssr/blind/editBatch',
    method: 'put',
    data: data
  })
}


// 确认盲板
export function handleConfirmApprove(data) {
  return request({
    url: '/pssr/blind/confirmBlind',
    method: 'put',
    data: data
  })
}
// 确认盲板
export function handleTurnDownBlind(data) {
  return request({
    url: '/pssr/blind/turnDownBlind',
    method: 'put',
    data: data
  })
}

// 删除盲板
export function delBlind(id) {
  return request({
    url: '/pssr/blind/' + id,
    method: 'delete'
  })
}

// 导出盲板
export function exportBlind(query) {
  return request({
    url: '/pssr/blind/export',
    method: 'get',
    params: query
  })
}
