import request from '@/utils/request'

// 查询密封点列表
export function listPoint(query) {
  return request({
    url: '/base/point/list',
    method: 'get',
    params: query
  })
}

export function listByPlan(query) {
  return request({
    url: '/base/point/listByPlan',
    method: 'get',
    params: query
  })
}

// 查询密封点详细
export function getPoint(id) {
  return request({
    url: '/base/point/' + id,
    method: 'get'
  })
}

// 新增密封点
export function addPoint(data) {
  return request({
    url: '/base/point',
    method: 'post',
    data: data
  })
}

// 修改密封点
export function updatePoint(data) {
  return request({
    url: '/base/point',
    method: 'put',
    data: data
  })
}

export function handleApprove(data) {
  return request({
    url: '/base/point/handleApprove',
    method: 'put',
    data: data
  })
}
export function handleApproveAll(data) {
  return request({
    url: '/base/point/handleApproveAll',
    method: 'put',
    data: data
  })
}
export function handleUpload(data) {
  return request({
    url: '/base/point/handleUpload',
    method: 'put',
    data: data
  })
}

// 删除密封点
export function delPoint(id) {
  return request({
    url: '/base/point/' + id,
    method: 'delete'
  })
}
