import request from '@/utils/request';
import { AxiosPromise } from 'axios';
import { KpiAssessmentVO } from './types';

/** 查询 KPI 考核列表 */
export function listKpiAssessment(query: any): AxiosPromise<KpiAssessmentVO[]> {
    return request({
        url: '/sale/kpi/list',
        method: 'get',
        params: query
    });
}

/** 导出 KPI 数据 */
export function exportKpi(query: any) {
    return request({
        url: '/sale/kpi/export',
        method: 'post',
        params: query,
        responseType: 'blob'
    });
}
