import fetch from 'utils/fetch';

// 員工業績報表列表
export function getDate(query) {
  return fetch({
    url: 'api/admin/staff_statistics/page',
    method: 'post',
    data: query
  });
}
// 員工業績報表導出
export function exports(query) {
  return fetch({
    url: 'api/admin/staff_statistics/export',
    method: 'post',
    data: query,
    responseType: 'blob'
  });
}

// 員工業績列表
export function companyList(query) {
  return fetch({
    url: '/api/order/report/form/list',
    method: 'post',
    data: query
  });
}

// 員工業績導出
export function excel(query) {
  return fetch({
    url: '/api/order/report/form/excel',
    method: 'post',
    data: query,
    responseType: 'blob'
  });
}

// 分公司业绩
export function company_performance(query) {
  return fetch({
    url: 'api/order/statistics/company_performance',
    method: 'post',
    data: query
  });
}

// 員工業績導出
export function excelExport(query) {
  return fetch({
    url: 'api/order/statistics/export',
    method: 'post',
    timeout: '600000',
    data: query,
    responseType: 'blob'
  });
}