import request from '@/router/axios';
//系统中期支付项分页
export const getList = (current, size, params) => {
  return request({
    url: '/api/blade-meter/mid/pay/item/system/page',
    method: 'post',
    data: {
      ...params,
      current,
      size,
    }
  })
}
//系统中期支付项列表
export const getAllList = (row) => {
  return request({
    url: '/api/blade-meter/mid/pay/item/system/list',
    method: 'post',
    params: row
  })
}
export const remove = (id) => {
  return request({
    url: '/api//blade-meter/mid/pay/item/system/remove',
    method: 'get',
    params: {
      id,
    }
  })
}

export const add = (row) => {
  return request({
    url: '/api/blade-meter/mid/pay/item/system/submit',
    method: 'post',
    data: row
  })
}

export const update = (row) => {
  return request({
    url: '/api/blade-meter/mid/pay/item/system/submit',
    method: 'post',
    data: row
  })
}

export const getDetail = (id) => {
  return request({
      url: '/api/blade-meter/mid/pay/item/system/detail',
      method: 'get',
      params: {
          id
      }
  })
}
//添加汇总项
export const addPay = (row) => {
  return request({
    url: '/api/blade-meter/mid/pay/item/bind/submit',
    method: 'post',
    params: row
  })
}
//删除汇总项
export const removePay = (row) => {
  return request({
    url: '/api/blade-meter/mid/pay/item/bind/remove',
    method: 'post',
    params: row
  })
}