import request from '@/utils/request'

// 查询录取原则列表
export function listMallAcceptRule(query) {
  return request({
    url: '/mall/mallAcceptRule/list',
    method: 'get',
    params: query
  })
}

// 查询录取原则列表
export function selectNewAcceptRuleList() {
  return request({
    url: '/mall/mallAcceptRule/selectNewAcceptRuleList',
    method: 'get'
  })
}

// 查询录取原则详细
export function getMallAcceptRule(acceptRuleId) {
  return request({
    url: '/mall/mallAcceptRule/' + acceptRuleId,
    method: 'get'
  })
}

// 新增录取原则
export function addMallAcceptRule(data) {
  return request({
    url: '/mall/mallAcceptRule',
    method: 'post',
    data: data
  })
}

// 修改录取原则
export function updateMallAcceptRule(data) {
  return request({
    url: '/mall/mallAcceptRule',
    method: 'put',
    data: data
  })
}

// 删除录取原则
export function delMallAcceptRule(acceptRuleId) {
  return request({
    url: '/mall/mallAcceptRule/' + acceptRuleId,
    method: 'delete'
  })
}

// 导入
export function importData() {
  return request({
    url: '/mall/mallAcceptRule/importData',
    method: 'post'
  })
}
