import request from '@/utils/request'

// 查询税务登记设立信息列表
export function listEstablishment(query) {
  return request({
    url: '/basicData/xcrTaxRegistrationEstablishment/findByPage',
    method: 'get',
    params: query
  })
}

// 查询税务登记设立信息详细
export function getEstablishment(xhCodeId) {
  return request({
    url: '/basicData/xcrTaxRegistrationEstablishment/' + xhCodeId,
    method: 'get'
  })
}

// 新增税务登记设立信息
export function addEstablishment(data) {
  return request({
    url: '/basicData/xcrTaxRegistrationEstablishment',
    method: 'post',
    data: data
  })
}

// 修改税务登记设立信息
export function updateEstablishment(data) {
  return request({
    url: '/basicData/xcrTaxRegistrationEstablishment',
    method: 'put',
    data: data
  })
}

// 删除税务登记设立信息
export function delEstablishment(xhCodeId) {
  return request({
    url: '/basicData/xcrTaxRegistrationEstablishment/deleteAll',
    method: 'delete'
  })
}
// 批量删除行政许可
export function delEstablishmentBatch(ids) {
  return request.post('/basicData/xcrTaxRegistrationEstablishment/delete',ids)
}
