mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-06 11:43:50 +00:00
Merge pull request #5672 from demonspork/Destination-Emergency
Add Support for Validated Emergency Destinations/Caller ID
This commit is contained in:
@@ -123,6 +123,9 @@
|
||||
$apps[$x]['permissions'][$y]['name'] = "destination_fax";
|
||||
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = "destination_emergency";
|
||||
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||
$y++;
|
||||
$apps[$x]['permissions'][$y]['name'] = "destination_destinations";
|
||||
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||
$apps[$x]['permissions'][$y]['groups'][] = "admin";
|
||||
@@ -287,6 +290,10 @@
|
||||
$apps[$x]['db'][$y]['fields'][$z]['type'] = "numeric";
|
||||
$apps[$x]['db'][$y]['fields'][$z]['description']['en-us'] = "Number is used for fax calls.";
|
||||
$z++;
|
||||
$apps[$x]['db'][$y]['fields'][$z]['name'] = "destination_type_emergency";
|
||||
$apps[$x]['db'][$y]['fields'][$z]['type'] = "numeric";
|
||||
$apps[$x]['db'][$y]['fields'][$z]['description']['en-us'] = "Number is used to place emergency calls.";
|
||||
$z++;
|
||||
$apps[$x]['db'][$y]['fields'][$z]['name'] = "destination_type_text";
|
||||
$apps[$x]['db'][$y]['fields'][$z]['type'] = "numeric";
|
||||
$apps[$x]['db'][$y]['fields'][$z]['description']['en-us'] = "Number is used for text messages.";
|
||||
|
||||
@@ -883,6 +883,27 @@ $text['label-text']['ru-ru'] = "Текст";
|
||||
$text['label-text']['sv-se'] = "Text";
|
||||
$text['label-text']['uk-ua'] = "Текст";
|
||||
|
||||
$text['label-emergency']['en-us'] = "Emergency";
|
||||
$text['label-emergency']['en-gb'] = "Emergency";
|
||||
$text['label-emergency']['ar-eg'] = "";
|
||||
$text['label-emergency']['de-at'] = "Anruferkennung"; //copied from de-de
|
||||
$text['label-emergency']['de-ch'] = "Anruferkennung";
|
||||
$text['label-emergency']['de-de'] = "Notruf Anruferkennung";
|
||||
$text['label-emergency']['es-cl'] = "Emergencia";
|
||||
$text['label-emergency']['es-mx'] = "Emergencia"; //copied from es-cl
|
||||
$text['label-emergency']['fr-ca'] = "Urgence"; //copied from fr-fr
|
||||
$text['label-emergency']['fr-fr'] = "Urgence";
|
||||
$text['label-emergency']['he-il'] = "";
|
||||
$text['label-emergency']['it-it'] = "Emergenze";
|
||||
$text['label-emergency']['nl-nl'] = "Noodnummer";
|
||||
$text['label-emergency']['pl-pl'] = "Prezentacja nazwy dzwoniącego (emergency)";
|
||||
$text['label-emergency']['pt-br'] = "Emergência";
|
||||
$text['label-emergency']['pt-pt'] = "Emergência";
|
||||
$text['label-emergency']['ro-ro'] = "";
|
||||
$text['label-emergency']['ru-ru'] = "Идентификатор (Caller ID) имени экстренного вызова";
|
||||
$text['label-emergency']['sv-se'] = "Nöd Namnpresentation";
|
||||
$text['label-emergency']['uk-ua'] = "";
|
||||
|
||||
$text['header-destinations']['en-us'] = "Destinations";
|
||||
$text['header-destinations']['en-gb'] = "Destinations";
|
||||
$text['header-destinations']['ar-eg'] = "جهات الأتصال";
|
||||
|
||||
@@ -107,6 +107,7 @@
|
||||
$destination_type_voice = $_POST["destination_type_voice"];
|
||||
$destination_type_fax = $_POST["destination_type_fax"];
|
||||
$destination_type_text = $_POST["destination_type_text"];
|
||||
$destination_type_emergency = $_POST["destination_type_emergency"];
|
||||
$destination_carrier = trim($_POST["destination_carrier"]);
|
||||
|
||||
//get the destination app and data
|
||||
@@ -671,6 +672,9 @@
|
||||
$array['destinations'][0]["destination_type_voice"] = $destination_type_voice ? 1 : null;
|
||||
$array['destinations'][0]["destination_type_fax"] = $destination_type_fax ? 1 : null;
|
||||
$array['destinations'][0]["destination_type_text"] = $destination_type_text ? 1 : null;
|
||||
if (permission_exists('destination_emergency')){
|
||||
$array['destinations'][0]["destination_type_emergency"] = $destination_type_emergency ? 1 : null;
|
||||
}
|
||||
if ($destination->valid($destination_app.':'.$destination_data)) {
|
||||
$array['destinations'][0]["destination_app"] = $destination_app;
|
||||
$array['destinations'][0]["destination_data"] = $destination_data;
|
||||
@@ -792,6 +796,7 @@
|
||||
$destination_type_voice = $row["destination_type_voice"];
|
||||
$destination_type_fax = $row["destination_type_fax"];
|
||||
$destination_type_text = $row["destination_type_text"];
|
||||
$destination_type_emergency = $row["destination_type_emergency"];
|
||||
$destination_context = $row["destination_context"];
|
||||
$destination_app = $row["destination_app"];
|
||||
$destination_data = $row["destination_data"];
|
||||
@@ -1239,6 +1244,9 @@
|
||||
echo " <label><input type='checkbox' name='destination_type_voice' id='destination_type_voice' value='1' ".($destination_type_voice ? "checked='checked'" : null)."> ".$text['label-voice']."</label> \n";
|
||||
echo " <label><input type='checkbox' name='destination_type_fax' id='destination_type_fax' value='1' ".($destination_type_fax ? "checked='checked'" : null)."> ".$text['label-fax']."</label> \n";
|
||||
echo " <label><input type='checkbox' name='destination_type_text' id='destination_type_text' value='1' ".($destination_type_text ? "checked='checked'" : null)."> ".$text['label-text']."</label>\n";
|
||||
if (permission_exists('destination_emergency')){
|
||||
echo " <label><input type='checkbox' name='destination_type_emergency' id='destination_type_emergency' value='1' ".($destination_type_emergency ? "checked='checked'" : null)."> ".$text['label-emergency']."</label>\n";
|
||||
}
|
||||
echo "<br />\n";
|
||||
echo $text['description-usage']."\n";
|
||||
echo "</td>\n";
|
||||
|
||||
Reference in New Issue
Block a user