Update xml_cdr.php

This commit is contained in:
FusionPBX
2018-10-17 22:08:20 -06:00
committed by GitHub
parent 32f794fb3f
commit fabc145bd7

View File

@@ -92,7 +92,7 @@ if (!class_exists('xml_cdr')) {
*/
public function fields() {
$this->fields[] = "uuid";
$this->fields[] = "xml_cdr_uuid";
$this->fields[] = "domain_uuid";
$this->fields[] = "extension_uuid";
$this->fields[] = "domain_name";
@@ -248,9 +248,9 @@ if (!class_exists('xml_cdr')) {
//Check in the database
$database = new database;
$database->table = "v_xml_cdr";
$where[1]["name"] = "uuid";
$where[1]["name"] = "xml_cdr_uuid";
$where[1]["operator"] = "=";
$where[1]["value"] = "$uuid";
$where[1]["value"] = $uuid;
$database->where = $where;
$result = $database->count();
if ($result > 0) {
@@ -300,7 +300,7 @@ if (!class_exists('xml_cdr')) {
//misc
$uuid = check_str(urldecode($xml->variables->uuid));
$this->array[$key]['uuid'] = $uuid;
$this->array[$key]['xml_cdr_uuid'] = $uuid;
$this->array[$key]['destination_number'] = check_str($destination_number);
$this->array[$key]['source_number'] = check_str(urldecode($xml->variables->effective_caller_id_number));
$this->array[$key]['user_context'] = check_str(urldecode($xml->variables->user_context));
@@ -1047,7 +1047,7 @@ if (!class_exists('xml_cdr')) {
$uuid = check_str($_GET['id']);
if ($uuid != '') {
$sql = "select record_name, record_path from v_xml_cdr ";
$sql .= "where uuid = '".$uuid."' ";
$sql .= "where xml_cdr_uuid = '".$uuid."' ";
//$sql .= "and domain_uuid = '".$domain_uuid."' \n";
$prep_statement = $this->db->prepare($sql);
$prep_statement->execute();