import request from '@/utils/request'

// 查询活动配置列表
export function listEvent(query) {
  return request({
    url: '/eventConfig/event/list',
    method: 'get',
    params: query
  })
}

// 查询活动配置详细
export function getEvent(id) {
  return request({
    url: '/eventConfig/event/' + id,
    method: 'get'
  })
}

// 新增活动配置
export function addEvent(data) {
  return request({
    url: '/eventConfig/event',
    method: 'post',
    data: data
  })
}

// 修改活动配置
export function updateEvent(data) {
  return request({
    url: '/eventConfig/event',
    method: 'put',
    data: data
  })
}

// 删除活动配置
export function delEvent(id) {
  return request({
    url: '/eventConfig/event/' + id,
    method: 'delete'
  })
}

// 导出活动配置
export function exportEvent(query) {
  return request({
    url: '/eventConfig/event/export',
    method: 'get',
    params: query
  })
}