From 139867815f354be6a46ce1815f03cdde919c936c Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Fri, 8 Nov 2024 17:21:18 -0700 Subject: [PATCH] Fix the extension summary and call flow summary Set the time zone in PHP so that it is correct inside the class method for the extension summary and the call flow summary --- app/xml_cdr/resources/classes/xml_cdr.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/xml_cdr/resources/classes/xml_cdr.php b/app/xml_cdr/resources/classes/xml_cdr.php index 5459950448..6b6a869131 100644 --- a/app/xml_cdr/resources/classes/xml_cdr.php +++ b/app/xml_cdr/resources/classes/xml_cdr.php @@ -1131,6 +1131,9 @@ if (!class_exists('xml_cdr')) { $time_zone = date_default_timezone_get(); } + //set the time zone for php + date_default_timezone_set($time_zone); + //get the destination select list $destination = new destinations; $destination_array = $destination->get('dialplan'); @@ -1627,6 +1630,9 @@ if (!class_exists('xml_cdr')) { $time_zone = date_default_timezone_get(); } + //set the time zone for php + date_default_timezone_set($time_zone); + //build the date range if ((!empty($this->start_stamp_begin) && strlen($this->start_stamp_begin) > 0) || !empty($this->start_stamp_end)) { unset($this->quick_select); @@ -1810,6 +1816,8 @@ if (!class_exists('xml_cdr')) { else { $sql .= " where true \n"; } + $sql .= "and leg = 'a' "; + $sql .= "and extension_uuid is not null "; $sql .= $sql_date_range; $sql .= ") as c \n";