import request from '@/utils/request'
import qs from 'qs'

export function getPhone(params) {
  return request({
    url: '/data/phone/history',
    method: 'get',
    params
  })
}

export function addPhone(data) {
  return request({
    url: '/data/phone',
    method: 'post',
    data
  })
}


export function editPhone(data) {
  return request({
    url: '/data/phone',
    method: 'put',
    data
  })
}

export function delPhone(data) {
  return request({
    url: '/data/phone',
    method: 'delete',
    data
  })
}

export function getPhoneMsgHis(params) {
  return request({
    // url: '/data/phoneHistory/history?'+ qs.stringify(params, { indices: false }),
    url: '/data/phoneHistory/history',
    method: 'get',
    params
  })
}