/**
 * 客户管理接口
 */
import request from '@/utils/request'
import qs from 'qs'

// 查询客户
export function getCustomerList(params) {
  return request({
    url: '/customer/listPage',
    method: 'get',
    params
  })
}
// 新增客户
export function addCustomer(params) {
  return request({
    url: '/customer/add',
    method: 'post',
    params
  })
}
// 编辑客户
export function updateCustomer(params) {
  return request({
    url: '/customer/update',
    method: 'post',
    params
  })
}

// 删除客户
export function delCustomer(ids) {
  return request({
    url: '/customer/delete',
    method: 'post',
    params: {
      ids: ids
    },
    paramsSerializer: params => {
      return qs.stringify(params, { indices: false })
    }
  })
}

