import request from '@/utils/request'

// 查询分期认缴信息列表
export function listSubscription(query) {
  return request({
    url: '/basicData/xcrInstallmentSubscription/findByPage',
    method: 'get',
    params: query
  })
}

// 查询分期认缴信息详细
export function getSubscription(xhCodeId) {
  return request({
    url: '/basicData/xcrInstallmentSubscription/' + xhCodeId,
    method: 'get'
  })
}

// 新增分期认缴信息
export function addSubscription(data) {
  return request({
    url: '/basicData/xcrInstallmentSubscription',
    method: 'post',
    data: data
  })
}

// 修改分期认缴信息
export function updateSubscription(data) {
  return request({
    url: '/basicData/xcrInstallmentSubscription',
    method: 'put',
    data: data
  })
}

// 删除分期认缴信息
export function delSubscription(xhCodeId) {
  return request({
    url: '/basicData/xcrInstallmentSubscription/deleteAll',
    method: 'delete'
  })
}
// 批量删除行政许可
export function delSubscriptionBatch(ids) {
  return request.post('/basicData/xcrInstallmentSubscription/delete',ids)
}
