Merge pull request #1139 from joernott/master
Allow provisioning with internal addressbook and update snom320 tpl
This commit is contained in:
commit
88a10cbea8
|
|
@ -743,6 +743,14 @@ include "root.php";
|
||||||
}
|
}
|
||||||
unset ($prep_statement);
|
unset ($prep_statement);
|
||||||
|
|
||||||
|
//populate internal address book
|
||||||
|
$sql = "SELECT extension as , effective_caller_id_name, effective_caller_id_number, outbound_caller_id_name, outbound_caller_id_number, directory_full_name FROM v_extensions";
|
||||||
|
$prep_statement = $this->db->prepare(check_sql($sql));
|
||||||
|
$prep_statement->execute();
|
||||||
|
$internal_addressbook = $prep_statement->fetchAll(PDO::FETCH_NAMED);
|
||||||
|
$view->assign("internal_addressbook",$internal_addressbook);
|
||||||
|
unset ($prep_statement);
|
||||||
|
|
||||||
//set the mac address in the correct format
|
//set the mac address in the correct format
|
||||||
$mac = $this->format_mac($mac, $device_vendor);
|
$mac = $this->format_mac($mac, $device_vendor);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -100,19 +100,30 @@
|
||||||
<codec_priority_list idx="12" perm="">g722,pcmu,pcma,gsm,g726-32,aal2-g726-32,g723,g729,telephone-event</codec_priority_list>
|
<codec_priority_list idx="12" perm="">g722,pcmu,pcma,gsm,g726-32,aal2-g726-32,g723,g729,telephone-event</codec_priority_list>
|
||||||
</phone-settings>
|
</phone-settings>
|
||||||
<functionKeys e="2">
|
<functionKeys e="2">
|
||||||
<fkey idx="0" context="active" label="" perm="">line</fkey>
|
{foreach $keys as $row}
|
||||||
<fkey idx="1" context="active" label="" perm="">line</fkey>
|
{if $row.device_key_line == ""}
|
||||||
<fkey idx="2" context="active" label="" perm="">line</fkey>
|
{if $row.device_key_category == "line"}
|
||||||
<fkey idx="3" context="active" label="" perm="">line</fkey>
|
<fkey idx="{$row.device_key_id-1}" context="active" label="{$row.device_key_label}" perm="">{$row.device_key_type} {$row.device_key_value} {$row.device_key_extension}</fkey>
|
||||||
<fkey idx="4" context="active" label="" perm="">line</fkey>
|
{else}
|
||||||
<fkey idx="5" context="active" label="" perm="">line</fkey>
|
<fkey idx="{$row.device_key_id}" context="active" label="" perm="">line</fkey>
|
||||||
<fkey idx="6" context="active" label="" perm="">line</fkey>
|
{/if}
|
||||||
<fkey idx="7" context="active" label="" perm="">line</fkey>
|
{else}
|
||||||
<fkey idx="8" context="active" label="" perm="">line</fkey>
|
{if $row.device_key_category == "line"}
|
||||||
<fkey idx="9" context="active" label="" perm="">line</fkey>
|
<fkey idx="{$row.device_key_id-1}" context="{$row.device_key_line}" label="{$row.device_key_label}" perm="">{$row.device_key_type} {$row.device_key_value} {$row.device_key_extension}</fkey>
|
||||||
<fkey idx="10" context="active" label="" perm="">line</fkey>
|
{else}
|
||||||
<fkey idx="11" context="active" label="" perm="">line</fkey>
|
<fkey idx="{$row.device_key_id}" context="active" label="" perm="">line</fkey>
|
||||||
|
{/if}
|
||||||
|
{/if}
|
||||||
|
{/foreach}
|
||||||
</functionKeys>
|
</functionKeys>
|
||||||
<tbook e="2">
|
<tbook e="2" complete="true">
|
||||||
|
{foreach $internal_addressbook as $address}
|
||||||
|
<item context="active" type="" fav="false">
|
||||||
|
<number>{$address.extension}</number>
|
||||||
|
<number_type>sip</number_type>
|
||||||
|
<first_name>{$address.directory_full_name} ({$address.extension})</first_name>
|
||||||
|
</item>
|
||||||
|
{/foreach}
|
||||||
|
|
||||||
</tbook>
|
</tbook>
|
||||||
</settings>
|
</settings>
|
||||||
Loading…
Reference in New Issue