From 5497ac121eccd0884d5cc939d8ce4f7b718b63f8 Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Fri, 20 Oct 2017 16:46:29 -0600 Subject: [PATCH] Update v_xml_cdr_import.php --- app/xml_cdr/v_xml_cdr_import.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/app/xml_cdr/v_xml_cdr_import.php b/app/xml_cdr/v_xml_cdr_import.php index 37f3ceee3f..c09cc03f02 100644 --- a/app/xml_cdr/v_xml_cdr_import.php +++ b/app/xml_cdr/v_xml_cdr_import.php @@ -296,6 +296,16 @@ $record_name = basename(urldecode($xml->variables->sofia_record_file)); $record_length = urldecode($xml->variables->record_seconds); } + elseif (strlen($xml->variables->api_on_answer) > 0) { + $command = str_replace("\n", " ", urldecode($xml->variables->api_on_answer)); + $parts = explode(" ", $command); + if ($parts[0] == "uuid_record") { + $recording = $parts[3]; + $record_path = dirname($recording); + $record_name = basename($recording); + } + $record_length = urldecode($xml->variables->duration); + } //add the call recording if (isset($record_path) && isset($record_name) && file_exists($record_path.'/'.$record_name) && $record_length > 0) {