Add Didar-style conversion rate to sales reports.
Show won-over-incoming deals for the selected period with time, user, and source breakdowns alongside the existing win-rate metric. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -2155,6 +2155,33 @@ export interface ReportsFunnelStageDto {
|
||||
shareOfPipelinePercent: number;
|
||||
}
|
||||
|
||||
/** یک ردیف نرخ تبدیل (ورودی → موفق) مثل دیدار */
|
||||
export interface ReportsConversionRateRowDto {
|
||||
key: string;
|
||||
label: string;
|
||||
incomingCount: number;
|
||||
wonCount: number;
|
||||
/** درصد؛ اگر ورودی صفر باشد ۰ */
|
||||
conversionPercent: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* نرخ تبدیل به سبک دیدار:
|
||||
* از معاملات تازهساختهشده در بازه، چند درصد الان برنده شدهاند.
|
||||
*/
|
||||
export interface ReportsConversionRateDto {
|
||||
incomingCount: number;
|
||||
wonCount: number;
|
||||
conversionPercent: number;
|
||||
previousIncomingCount: number;
|
||||
previousWonCount: number;
|
||||
previousConversionPercent: number;
|
||||
changePercent: number | null;
|
||||
byTime: ReportsConversionRateRowDto[];
|
||||
byUser: ReportsConversionRateRowDto[];
|
||||
bySource: ReportsConversionRateRowDto[];
|
||||
}
|
||||
|
||||
export interface ReportsPeriodCompareRowDto {
|
||||
key: string;
|
||||
label: string;
|
||||
@@ -2219,6 +2246,8 @@ export interface ReportsDashboardDto {
|
||||
winRate: number;
|
||||
};
|
||||
funnel: ReportsFunnelStageDto[];
|
||||
/** نرخ تبدیل ورودی→موفق (سبک دیدار) */
|
||||
conversionRate: ReportsConversionRateDto;
|
||||
/** مقایسه صریح بازه فعلی با دوره قبل همطول */
|
||||
periodCompare: ReportsPeriodCompareRowDto[];
|
||||
tickets: {
|
||||
|
||||
Reference in New Issue
Block a user