import request from '@/utils/request'

// 监督员考核列表查询
export function assessSupervisor(params) {
  return request({
    url: '/assess/supervisor',
    method: 'get',
    params
  })
}
// 监督员考核列表导出
export function exportAssessSupervisor(params) {
  return request({
    url: '/assess/batchExport',
    method: 'get',
    timeout: 120000,
    params: { ...params, type: 'supervisor' },
    responseType: 'blob' // 这一步也很关键，一定要加上 responseType 值为 blob
  })
}

// 受理员考核列表查询
export function assessReceiver(params) {
  return request({
    url: '/assess/receiver',
    method: 'get',
    params
  })
}
// 受理员考核列表导出
export function exportAssessReceiver(params) {
  return request({
    url: '/assess/batchExport',
    method: 'get',
    timeout: 120000,
    params: { ...params, type: 'receiver' },
    responseType: 'blob' // 这一步也很关键，一定要加上 responseType 值为 blob
  })
}

// 受理员考核列表查询
export function assessMonitor(params) {
  return request({
    url: '/assess/monitor',
    method: 'get',
    params
  })
}
// 受理员考核列表导出
export function exportAssessMonitor(params) {
  return request({
    url: '/assess/batchExport',
    method: 'get',
    timeout: 120000,
    params: { ...params, type: 'monitor' },
    responseType: 'blob' // 这一步也很关键，一定要加上 responseType 值为 blob
  })
}

// 受理员考核列表查询
export function assessDispatcher(params) {
  return request({
    url: '/assess/dispatcher',
    method: 'get',
    params
  })
}
// 受理员考核列表导出
export function exportAssessDispatcher(params) {
  return request({
    url: '/assess/batchExport',
    method: 'get',
    timeout: 120000,
    params: { ...params, type: 'dispatcher' },
    responseType: 'blob' // 这一步也很关键，一定要加上 responseType 值为 blob
  })
}
