import request from '@/utils/request'

// 查询客户联系人列表
export function listCustomerContacts(query) {
  return request({
    url: '/crm/customerContacts/list',
    method: 'get',
    params: query
  })
}

// 查询客户联系人详细
export function getCustomerContacts(contactsId) {
  return request({
    url: '/crm/customerContacts/' + contactsId,
    method: 'get'
  })
}

// 新增客户联系人
export function addCustomerContacts(data) {
  return request({
    url: '/crm/customerContacts',
    method: 'post',
    data: data
  })
}

// 修改客户联系人
export function updateCustomerContacts(data) {
  return request({
    url: '/crm/customerContacts',
    method: 'put',
    data: data
  })
}

// 删除客户联系人
export function delCustomerContacts(contactsId) {
  return request({
    url: '/crm/customerContacts/' + contactsId,
    method: 'delete'
  })
}

// 导出客户联系人
export function exportCustomerContacts(query) {
  return request({
    url: '/crm/customerContacts/export',
    method: 'get',
    params: query
  })
}