import request from '@/utils/request'

// 查询会员权益列表
export function listRights(query) {
  return request({
    url: '/base/rights/list',
    method: 'get',
    params: query
  })
}

// 查询会员权益详细
export function getRights(id) {
  return request({
    url: '/base/rights/' + id,
    method: 'get'
  })
}

// 新增会员权益
export function addRights(data) {
  return request({
    url: '/base/rights',
    method: 'post',
    data: data
  })
}

// 修改会员权益
export function updateRights(data) {
  return request({
    url: '/base/rights',
    method: 'put',
    data: data
  })
}

// 删除会员权益
export function delRights(id) {
  return request({
    url: '/base/rights/' + id,
    method: 'delete'
  })
}
