import request from '@/utils/request'

// 查询消费扣款记录列表
export function listApi(query) {
  return request({
    url: '/consumeRecord/list',
    method: 'get',
    params: query
  })
}

// 查询消费扣款记录详细
export function getApi(id) {
  return request({
    url: '/consumeRecord/' + id,
    method: 'get'
  })
}

// 新增消费扣款记录
export function addApi(data) {
  return request({
    url: '/consumeRecord',
    method: 'post',
    data: data
  })
}

// 修改消费扣款记录
export function updateApi(data) {
  return request({
    url: '/consumeRecord',
    method: 'put',
    data: data
  })
}

// 删除消费扣款记录
export function delApi(id) {
  return request({
    url: '/consumeRecord/' + id,
    method: 'delete'
  })
}
