- 迁移 CRM 销售漏斗分析,补充漏斗图、阶段统计和商机转化率分析 - 迁移 CRM 员工业绩分析,补充合同汇总统计 - 迁移 CRM 产品分析,新增产品销售情况和产品分类销售分析 - 新增 CRM 业绩达成统计,支持销售目标和回款目标达成情况展示 - 新增 CRM 业绩目标设置,支持部门和员工维度的目标配置 - 补充 web-antd、web-antdv-next、web-ele 对应 API 和页面实现 - 调整统计图表配置、筛选项和表格展示,统一多端 CRM 统计交互
67 lines
1.8 KiB
TypeScript
67 lines
1.8 KiB
TypeScript
import { requestClient } from '#/api/request';
|
|
|
|
export namespace CrmStatisticsPerformanceApi {
|
|
/** 员工业绩统计请求 */
|
|
export interface PerformanceReqVO {
|
|
times: string[];
|
|
deptId: number;
|
|
userId?: number;
|
|
}
|
|
|
|
/** 员工业绩统计响应 */
|
|
export interface PerformanceRespVO {
|
|
time: string;
|
|
currentMonthCount: number;
|
|
lastMonthCount: number;
|
|
lastYearCount: number;
|
|
}
|
|
|
|
/** 员工业绩合同汇总响应 */
|
|
export interface PerformanceSummaryRespVO {
|
|
time: string;
|
|
contractCount: number;
|
|
contractPrice: number;
|
|
receivablePrice: number;
|
|
unreceivedPrice: number;
|
|
}
|
|
}
|
|
|
|
/** 员工获得合同金额统计 */
|
|
export function getContractPricePerformance(
|
|
params: CrmStatisticsPerformanceApi.PerformanceReqVO,
|
|
) {
|
|
return requestClient.get<CrmStatisticsPerformanceApi.PerformanceRespVO[]>(
|
|
'/crm/statistics-performance/get-contract-price-performance',
|
|
{ params },
|
|
);
|
|
}
|
|
|
|
/** 员工获得回款统计 */
|
|
export function getReceivablePricePerformance(
|
|
params: CrmStatisticsPerformanceApi.PerformanceReqVO,
|
|
) {
|
|
return requestClient.get<CrmStatisticsPerformanceApi.PerformanceRespVO[]>(
|
|
'/crm/statistics-performance/get-receivable-price-performance',
|
|
{ params },
|
|
);
|
|
}
|
|
|
|
/** 员工获得签约合同数量统计 */
|
|
export function getContractCountPerformance(
|
|
params: CrmStatisticsPerformanceApi.PerformanceReqVO,
|
|
) {
|
|
return requestClient.get<CrmStatisticsPerformanceApi.PerformanceRespVO[]>(
|
|
'/crm/statistics-performance/get-contract-count-performance',
|
|
{ params },
|
|
);
|
|
}
|
|
|
|
/** 获得合同汇总表 */
|
|
export function getContractSummary(
|
|
params: CrmStatisticsPerformanceApi.PerformanceReqVO,
|
|
) {
|
|
return requestClient.get<
|
|
CrmStatisticsPerformanceApi.PerformanceSummaryRespVO[]
|
|
>('/crm/statistics-performance/get-contract-summary', { params });
|
|
}
|