start of local extensions as remote phone book

This commit is contained in:
blackc2004
2016-01-13 10:08:38 -08:00
parent 5ad0b07eb5
commit 28aec4f0a9
7 changed files with 64 additions and 9 deletions

View File

@@ -522,11 +522,12 @@ include "root.php";
if (strlen($device_uuid) > 0 and strlen($domain_uuid) > 0 and $_SESSION['provision']['directory_extensions']['boolean'] == "true") {
//get contacts from the database
$sql = "select directory_full_name, description ";
$sql .= "effective_caller_id_name, effective_caller_id_number ";
$sql .= "effective_caller_id_name, effective_caller_id_number, ";
$sql .= "number_alias, extension ";
$sql .= "from v_extensions ";
$sql .= "where domain_uuid = '".$_SESSION['domain_uuid']."' ";
$sql .= "where domain_uuid = '".$domain_uuid."' ";
$sql .= "and enabled = 'true' ";
$prep_statement = $db->prepare($sql);
$prep_statement = $this->db->prepare($sql);
if ($prep_statement) {
$prep_statement->execute();
$extensions = $prep_statement->fetchAll(PDO::FETCH_NAMED);