import request from '@/utils/request'

// 查询多商户配置列表
export function listMore(query) {
  return request({
    url: '/store/redPacket/more/list',
    method: 'get',
    params: query
  })
}


export function getRedPacketMchId(query) {
  return request({
    url: '/store/redPacket/more/getRedPacketConfig',
    method: 'get',
    params: query
  })
}


// 查询多商户配置详细
export function getMore(id) {
  return request({
    url: '/store/redPacket/more/' + id,
    method: 'get'
  })
}

// 新增多商户配置
export function addMore(data) {
  return request({
    url: '/store/redPacket/more',
    method: 'post',
    data: data
  })
}

// 修改多商户配置
export function updateMore(data) {
  return request({
    url: '/store/redPacket/more',
    method: 'put',
    data: data
  })
}

export function updateChangeMchId(data) {
  return request({
    url: '/store/redPacket/more/updateChangeMchId',
    method: 'post',
    data: data
  })
}

// 删除多商户配置
export function delMore(id) {
  return request({
    url: '/store/redPacket/more/' + id,
    method: 'delete'
  })
}

// 导出多商户配置
export function exportMore(query) {
  return request({
    url: '/store/redPacket/more/export',
    method: 'get',
    params: query
  })
}
