import request from '@/utils/request'

// 查询banner图列表
export function listBanner(query) {
  return request({
    url: '/business/banner/list',
    method: 'get',
    params: query
  })
}

// 查询banner图详细
export function getBanner(id) {
  return request({
    url: '/business/banner/' + id,
    method: 'get'
  })
}

// 新增banner图
export function addBanner(data) {
  return request({
    url: '/business/banner',
    method: 'post',
    data: data
  })
}

// 修改banner图
export function updateBanner(data) {
  return request({
    url: '/business/banner',
    method: 'put',
    data: data
  })
}

// 删除banner图
export function delBanner(id) {
  return request({
    url: '/business/banner/' + id,
    method: 'delete'
  })
}

// 导出banner图
export function exportBanner(query) {
  return request({
    url: '/business/banner/export',
    method: 'get',
    params: query
  })
}