import request from '@/utils/request'


const panelApi = {
  customerDetail: (query) => {
    return request({
      url: '/customer/detail',
      method: 'get',
      params: query
    })
  },
  switchCustomer: (query) => {
    return request({
      url: '/customer/find',
      method: 'get',
      params: query
    })
  },
  updateCustomer: (data) => {
    return request({
      url: '/customer/update',
      method: 'post',
      data
    })
  },
  // 话务记录
  calllogRecord: (query) => {
    return request({
      url: '/calllogRecord/list',
      method: 'get',
      params: query
    })
  },

  // 电访结果
  calllogCreate: (data) => {
    return request({
      url: '/calllog/create',
      method: 'post',
      data
    })
  },

  // 咨询投诉内容列表
  ticketConsultList: (query) => {
    return request({
      url: '/ticketConsult/list',
      method: 'get',
      params: query
    })
  },

  // 盒马商品列表
  goodsList: (query) => {
    return request({
      url: '/goodsCategory/list',
      method: 'get',
      params: query
    })
  },
  // 服务单列表
 serviceList: (query) => {
    return request({
      url: '/bookOrder/selectByCustomerId',
      method: 'get',
      params: query
    })
  },
  // 工单处理结果
  ticketResult: (query) => {
    return request({
      url: '/ticket/ticketResult',
      method: 'get',
      params: query
    })
  },

  // 完成流转工单
  ticketCreate: (data) => {
    return request({
      url: '/ticket/create',
      method: 'post',
      data
    })
  },

    // 更新订单
    updateJzOrder: (query) => {
      return request({
        url: '/order/syncOrderByUserId',
        method: 'get',
        params: query
      })
    },

     // 首页数据
     getIndexData: (query) => {
      return request({
        url: 'index/index',
        method: 'get',
        params: query
      })
    },


};
export default panelApi;

