import request from '@/utils/request'

// 查询客户公海信息列表（基于 customer_info 表查询）
export function listPool(query) {
  return request({
    url: '/customer/customerInfo/highseas',
    method: 'get',
    params: query
  })
}

// 获取详情
export function getPool(id) {
  return request({
      url: `/customer/customerInfo/${id}`,
      method: 'get'
  })
}

// 认领客户
export function claimPool(data) {
  return request({
    url: '/customer/customerInfo/claim',
    method: 'post',
    data: data
  })
}

// 新增客户公海
export function addPool(data) {
  return request({
    url: '/customer/customerInfo',
    method: 'post',
    data: data
  })
}

// 修改客户公海
export function updatePool(data) {
  return request({
    url: '/customer/customerInfo',
    method: 'put',
    data: data
  })
}
