import request from '@/utils/request'

// 查询业主车位列表
export function listCarport(query) {
  return request({
    url: '/business/carport/list',
    method: 'get',
    params: query
  })
}

// 查询业主车位详细
export function getCarport(carportId) {
  return request({
    url: '/business/carport/' + carportId,
    method: 'get'
  })
}

// 新增业主车位
export function addCarport(data) {
  return request({
    url: '/business/carport',
    method: 'post',
    data: data
  })
}

// 修改业主车位
export function updateCarport(data) {
  return request({
    url: '/business/carport',
    method: 'put',
    data: data
  })
}

// 删除业主车位
export function delCarport(carportId) {
  return request({
    url: '/business/carport/' + carportId,
    method: 'delete'
  })
}
