From ad16e92763a69892f42eaffbc357c98a41ba5978 Mon Sep 17 00:00:00 2001 From: johnnyq Date: Mon, 2 Mar 2026 18:06:54 -0500 Subject: [PATCH] Use true Decimal minute reporting in Client Time Audit Detail Report --- agent/reports/client_ticket_time_detail.php | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/agent/reports/client_ticket_time_detail.php b/agent/reports/client_ticket_time_detail.php index b84f3402..bfafacf4 100644 --- a/agent/reports/client_ticket_time_detail.php +++ b/agent/reports/client_ticket_time_detail.php @@ -16,16 +16,13 @@ function secondsToHmsString($seconds) { } /** - * 15-minute round up, return decimal hours in 0.25 increments - * NOTE: In this report, billed hours are calculated per TICKET total - * (sum of reply time within range, then rounded up to nearest 15 minutes). + * Convert seconds to true decimal hours (rounded to 2 decimals). */ -function secondsToQuarterHourDecimal($seconds) { +function secondsToDecimalHours($seconds) { $seconds = (int) max(0, $seconds); if ($seconds === 0) return 0.00; - $quarters = (int) ceil($seconds / 900); // 900 seconds = 15 minutes - return $quarters * 0.25; + return round($seconds / 3600, 2); } /** @@ -162,7 +159,7 @@ $result = $stmt->get_result(); Ticket Total for @@ -314,7 +311,7 @@ $result = $stmt->get_result(); - +