diff --git a/frontend/src/components/SprintTable.vue b/frontend/src/components/SprintTable.vue index 377b227..54d9c0b 100644 --- a/frontend/src/components/SprintTable.vue +++ b/frontend/src/components/SprintTable.vue @@ -105,6 +105,7 @@ watch( Lead Time Количество заходов на тестирование Flow Efficiency + Переработка max @@ -120,6 +121,11 @@ watch( min max 50pp + max + min + 95pp + 80pp + 50pp @@ -155,6 +161,11 @@ watch( {{ formatEfficiency(sprint.efficiency_min) }} {{ formatEfficiency(sprint.efficiency_max) }} {{ formatEfficiency(sprint.efficiency_p50) }} + {{ formatEfficiency(sprint.recast_max) }} + {{ formatEfficiency(sprint.recast_min) }} + {{ formatEfficiency(sprint.recast_p95) }} + {{ formatEfficiency(sprint.recast_p80) }} + {{ formatEfficiency(sprint.recast_p50) }} diff --git a/frontend/src/types.ts b/frontend/src/types.ts index 0abfa70..3580c5f 100644 --- a/frontend/src/types.ts +++ b/frontend/src/types.ts @@ -23,4 +23,9 @@ export interface Sprint { efficiency_min: number | null efficiency_max: number | null efficiency_p50: number | null + recast_max: number | null + recast_min: number | null + recast_p95: number | null + recast_p80: number | null + recast_p50: number | null } diff --git a/src/Features/Reports/ReportsApi.php b/src/Features/Reports/ReportsApi.php index 054190c..196613a 100644 --- a/src/Features/Reports/ReportsApi.php +++ b/src/Features/Reports/ReportsApi.php @@ -49,7 +49,12 @@ final class ReportsApi { * test_count_p50: float|null, * efficiency_min: float|null, * efficiency_max: float|null, - * efficiency_p50: float|null + * efficiency_p50: float|null, + * recast_max: float|null, + * recast_min: float|null, + * recast_p95: float|null, + * recast_p80: float|null, + * recast_p50: float|null * }> */ public function getSprintsByTeamId(int $teamId): array { @@ -79,7 +84,15 @@ final class ReportsApi { MIN(t.efficiency_percentage) FILTER (WHERE t.efficiency_percentage IS NOT NULL) AS efficiency_min, MAX(t.efficiency_percentage) FILTER (WHERE t.efficiency_percentage IS NOT NULL) AS efficiency_max, percentile_cont(0.50) WITHIN GROUP (ORDER BY t.efficiency_percentage) - FILTER (WHERE t.efficiency_percentage IS NOT NULL) AS efficiency_p50 + FILTER (WHERE t.efficiency_percentage IS NOT NULL) AS efficiency_p50, + MAX(t.recast_percentage) FILTER (WHERE t.recast_percentage IS NOT NULL) AS recast_max, + MIN(t.recast_percentage) FILTER (WHERE t.recast_percentage IS NOT NULL) AS recast_min, + percentile_cont(0.95) WITHIN GROUP (ORDER BY t.recast_percentage) + FILTER (WHERE t.recast_percentage IS NOT NULL) AS recast_p95, + percentile_cont(0.80) WITHIN GROUP (ORDER BY t.recast_percentage) + FILTER (WHERE t.recast_percentage IS NOT NULL) AS recast_p80, + percentile_cont(0.50) WITHIN GROUP (ORDER BY t.recast_percentage) + FILTER (WHERE t.recast_percentage IS NOT NULL) AS recast_p50 FROM sprints s LEFT JOIN tasks t ON t.sprint_id = s.id LEFT JOIN employees e ON e.id = t.employee_id @@ -117,6 +130,11 @@ final class ReportsApi { 'efficiency_min' => $row['efficiency_min'] !== null ? (float) $row['efficiency_min'] : null, 'efficiency_max' => $row['efficiency_max'] !== null ? (float) $row['efficiency_max'] : null, 'efficiency_p50' => $row['efficiency_p50'] !== null ? (float) $row['efficiency_p50'] : null, + 'recast_max' => $row['recast_max'] !== null ? (float) $row['recast_max'] : null, + 'recast_min' => $row['recast_min'] !== null ? (float) $row['recast_min'] : null, + 'recast_p95' => $row['recast_p95'] !== null ? (float) $row['recast_p95'] : null, + 'recast_p80' => $row['recast_p80'] !== null ? (float) $row['recast_p80'] : null, + 'recast_p50' => $row['recast_p50'] !== null ? (float) $row['recast_p50'] : null, ], $rows );