import request from '@/utils/request'

// 分页查询代理产品权限列表
export function pageListProduct(query) {
  return request({
    url: '/broker/product/pageList',
    method: 'get',
    params: query
  })
}

// 查询代理产品权限列表
export function listProduct(query) {
  return request({
    url: '/broker/product/list',
    method: 'get',
    params: query
  })
}

// 查询代理产品权限详细
export function getProduct(id) {
  return request({
    url: '/broker/product/' + id,
    method: 'get'
  })
}

// 新增代理产品权限
export function addProduct(data) {
  return request({
    url: '/broker/product',
    method: 'post',
    data: data
  })
}

// 修改代理产品权限
export function updateProduct(data) {
  return request({
    url: '/broker/product',
    method: 'put',
    data: data
  })
}

// 删除代理产品权限
export function delProduct(id) {
  return request({
    url: '/broker/product/' + id,
    method: 'delete'
  })
}

// 导出代理产品权限
export function exportProduct(query) {
  return request({
    url: '/broker/product/' + 'export',
    method: 'post',
    params: query
  })
}
