diff --git a/app/destinations/app_config.php b/app/destinations/app_config.php
index 97348e11bc..fbeb05477f 100644
--- a/app/destinations/app_config.php
+++ b/app/destinations/app_config.php
@@ -184,6 +184,18 @@
$apps[$x]['db'][$y]['fields'][$z]['type'] = "text";
$apps[$x]['db'][$y]['fields'][$z]['description']['en-us'] = "Enter the accountcode.";
$z++;
+ $apps[$x]['db'][$y]['fields'][$z]['name'] = "destination_type_voice";
+ $apps[$x]['db'][$y]['fields'][$z]['type'] = "numeric";
+ $apps[$x]['db'][$y]['fields'][$z]['description']['en-us'] = "Number is used for voice calls.";
+ $z++;
+ $apps[$x]['db'][$y]['fields'][$z]['name'] = "destination_type_fax";
+ $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_text";
+ $apps[$x]['db'][$y]['fields'][$z]['type'] = "numeric";
+ $apps[$x]['db'][$y]['fields'][$z]['description']['en-us'] = "Number is used for text messages.";
+ $z++;
$apps[$x]['db'][$y]['fields'][$z]['name'] = "destination_app";
$apps[$x]['db'][$y]['fields'][$z]['type'] = "text";
$apps[$x]['db'][$y]['fields'][$z]['description']['en-us'] = "Enter the application.";
diff --git a/app/destinations/app_languages.php b/app/destinations/app_languages.php
index 7288b093c3..a422050f31 100644
--- a/app/destinations/app_languages.php
+++ b/app/destinations/app_languages.php
@@ -621,6 +621,86 @@ $text['label-detail_action']['ru-ru'] = "Действия";
$text['label-detail_action']['sv-se'] = "Åtgärder";
$text['label-detail_action']['uk-ua'] = "Дії";
+$text['label-usage']['en-us'] = "Usage";
+$text['label-usage']['ar-eg'] = "";
+$text['label-usage']['de-at'] = "";
+$text['label-usage']['de-ch'] = "";
+$text['label-usage']['de-de'] = "";
+$text['label-usage']['es-cl'] = "";
+$text['label-usage']['es-mx'] = "";
+$text['label-usage']['fr-ca'] = "";
+$text['label-usage']['fr-fr'] = "";
+$text['label-usage']['he-il'] = "";
+$text['label-usage']['it-it'] = "";
+$text['label-usage']['nl-nl'] = "";
+$text['label-usage']['pl-pl'] = "";
+$text['label-usage']['pt-br'] = "";
+$text['label-usage']['pt-pt'] = "";
+$text['label-usage']['ro-ro'] = "";
+$text['label-usage']['ru-ru'] = "";
+$text['label-usage']['sv-se'] = "";
+$text['label-usage']['uk-ua'] = "";
+
+$text['label-voice']['en-us'] = "Voice";
+$text['label-voice']['ar-eg'] = "";
+$text['label-voice']['de-at'] = "Sprache"; //copied from de-de
+$text['label-voice']['de-ch'] = "Sprache"; //copied from de-de
+$text['label-voice']['de-de'] = "Sprache";
+$text['label-voice']['es-cl'] = "Voz";
+$text['label-voice']['es-mx'] = "Voz"; //copied from es-cl
+$text['label-voice']['fr-ca'] = "Voix"; //copied from fr-fr
+$text['label-voice']['fr-fr'] = "Voix";
+$text['label-voice']['he-il'] = "שיחה";
+$text['label-voice']['it-it'] = "Voce";
+$text['label-voice']['nl-nl'] = "";
+$text['label-voice']['pl-pl'] = "Głos";
+$text['label-voice']['pt-br'] = "Voz"; //copied from pt-pt
+$text['label-voice']['pt-pt'] = "Voz";
+$text['label-voice']['ro-ro'] = "";
+$text['label-voice']['ru-ru'] = "Голос";
+$text['label-voice']['sv-se'] = "Röst";
+$text['label-voice']['uk-ua'] = "Голос";
+
+$text['label-fax']['en-us'] = "Fax";
+$text['label-fax']['ar-eg'] = "";
+$text['label-fax']['de-at'] = "Fax"; //copied from de-de
+$text['label-fax']['de-ch'] = "Fax"; //copied from de-de
+$text['label-fax']['de-de'] = "Fax";
+$text['label-fax']['es-cl'] = "Facsímil";
+$text['label-fax']['es-mx'] = "Facsímil"; //copied from es-cl
+$text['label-fax']['fr-ca'] = "Télécopie"; //copied from fr-fr
+$text['label-fax']['fr-fr'] = "Télécopie";
+$text['label-fax']['he-il'] = "פקס";
+$text['label-fax']['it-it'] = "Fax";
+$text['label-fax']['nl-nl'] = "";
+$text['label-fax']['pl-pl'] = "Faks";
+$text['label-fax']['pt-br'] = "FAX";
+$text['label-fax']['pt-pt'] = "Fax";
+$text['label-fax']['ro-ro'] = "";
+$text['label-fax']['ru-ru'] = "Факс";
+$text['label-fax']['sv-se'] = "Fax";
+$text['label-fax']['uk-ua'] = "Факс";
+
+$text['label-text']['en-us'] = "Text";
+$text['label-text']['ar-eg'] = "";
+$text['label-text']['de-at'] = "Text"; //copied from de-de
+$text['label-text']['de-ch'] = "Text"; //copied from de-de
+$text['label-text']['de-de'] = "Text";
+$text['label-text']['es-cl'] = "Texto";
+$text['label-text']['es-mx'] = "Texto"; //copied from es-cl
+$text['label-text']['fr-ca'] = "Texte"; //copied from fr-fr
+$text['label-text']['fr-fr'] = "Texte";
+$text['label-text']['he-il'] = "טקסט";
+$text['label-text']['it-it'] = "Testo";
+$text['label-text']['nl-nl'] = "";
+$text['label-text']['pl-pl'] = "Tekst";
+$text['label-text']['pt-br'] = "Texto"; //copied from pt-pt
+$text['label-text']['pt-pt'] = "Texto";
+$text['label-text']['ro-ro'] = "";
+$text['label-text']['ru-ru'] = "Текст";
+$text['label-text']['sv-se'] = "Text";
+$text['label-text']['uk-ua'] = "Текст";
+
$text['header-destinations']['en-us'] = "Destinations";
$text['header-destinations']['ar-eg'] = "جهات الأتصال";
$text['header-destinations']['de-at'] = "Ziele"; //copied from de-de
@@ -1021,6 +1101,26 @@ $text['description-account_code']['ru-ru'] = "Введите код учетно
$text['description-account_code']['sv-se'] = "Ange 'account code'.";
$text['description-account_code']['uk-ua'] = "Введіть код облікового запису";
+$text['description-usage']['en-us'] = "Set how the Destination will be used.";
+$text['description-usage']['ar-eg'] = "";
+$text['description-usage']['de-at'] = "";
+$text['description-usage']['de-ch'] = "";
+$text['description-usage']['de-de'] = "";
+$text['description-usage']['es-cl'] = "";
+$text['description-usage']['es-mx'] = "";
+$text['description-usage']['fr-ca'] = "";
+$text['description-usage']['fr-fr'] = "";
+$text['description-usage']['he-il'] = "";
+$text['description-usage']['it-it'] = "";
+$text['description-usage']['nl-nl'] = "";
+$text['description-usage']['pl-pl'] = "";
+$text['description-usage']['pt-br'] = "";
+$text['description-usage']['pt-pt'] = "";
+$text['description-usage']['ro-ro'] = "";
+$text['description-usage']['ru-ru'] = "";
+$text['description-usage']['sv-se'] = "";
+$text['description-usage']['uk-ua'] = "";
+
$text['billing-warning']['en-us'] = "If you are using fusionpbx billing application, make sure to add accountcode and carrier variables.";
$text['billing-warning']['ar-eg'] = "";
$text['billing-warning']['de-at'] = "Wenn Sie die Fusionpbx Abrechnung verwenden, stellen Sie sicher, dass Account-Code und Betreiber-Variablen gesetzt sind."; //copied from de-de
diff --git a/app/destinations/destination_edit.php b/app/destinations/destination_edit.php
index 72874e1007..7706fa6241 100644
--- a/app/destinations/destination_edit.php
+++ b/app/destinations/destination_edit.php
@@ -108,6 +108,9 @@
$currency_buy = trim($_POST["currency_buy"]);
$destination_record = trim($_POST["destination_record"]);
$destination_accountcode = trim($_POST["destination_accountcode"]);
+ $destination_type_voice = check_str($_POST["destination_type_voice"]);
+ $destination_type_fax = check_str($_POST["destination_type_fax"]);
+ $destination_type_text = check_str($_POST["destination_type_text"]);
$destination_carrier = trim($_POST["destination_carrier"]);
//convert the number to a regular expression
$destination_number_regex = string_to_regex($destination_number);
@@ -131,7 +134,7 @@
unset($_POST["db_destination_number"]);
}
-//process the http post
+//process the http post
if (count($_POST) > 0 && strlen($_POST["persistformvar"]) == 0) {
//get the uuid
@@ -589,6 +592,9 @@
$destination["destination_context"] = $destination_context;
$destination["destination_record"] = $destination_record;
$destination["destination_accountcode"] = $destination_accountcode;
+ $destination["destination_type_voice"] = $destination_type_voice ? 1 : null;
+ $destination["destination_type_fax"] = $destination_type_fax ? 1 : null;
+ $destination["destination_type_text"] = $destination_type_text ? 1 : null;
$destination["destination_app"] = $destination_app;
$destination["destination_data"] = $destination_data;
$destination["destination_alternate_app"] = $destination_alternate_app;
@@ -697,6 +703,9 @@
$destination_cid_name_prefix = $row["destination_cid_name_prefix"];
$destination_record = $row["destination_record"];
$destination_accountcode = $row["destination_accountcode"];
+ $destination_type_voice = $row["destination_type_voice"];
+ $destination_type_fax = $row["destination_type_fax"];
+ $destination_type_text = $row["destination_type_text"];
$destination_context = $row["destination_context"];
$destination_app = $row["destination_app"];
$destination_data = $row["destination_data"];
@@ -1057,6 +1066,19 @@
echo $text['description-account_code']."\n";
echo "\n";
+ echo "
\n";
+ echo "| \n";
+ echo " ".$text['label-usage']."\n";
+ echo " | \n";
+ echo "\n";
+ echo " \n";
+ echo " \n";
+ echo " \n";
+ echo " \n";
+ echo $text['description-usage']."\n";
+ echo " | \n";
+ echo "
\n";
+
if (permission_exists('destination_domain')) {
echo "\n";
echo "\n";
diff --git a/app/messages/messages.php b/app/messages/messages.php
index d2de142d0b..e95270f6f9 100644
--- a/app/messages/messages.php
+++ b/app/messages/messages.php
@@ -42,6 +42,7 @@
//get (from) destinations
$sql = "select destination_number from v_destinations ";
$sql .= "where domain_uuid = '".$domain_uuid."' ";
+ $sql .= "and destination_type_text = 1 ";
$sql .= "and destination_enabled = 'true' ";
$sql .= "order by destination_number asc ";
$prep_statement = $db->prepare(check_sql($sql));
@@ -99,6 +100,10 @@
echo " vertical-align: middle;\n";
echo " }\n";
+ echo " td.contact_selected {\n";
+ echo " border-right: 5px solid ".($SESSION['theme']['table_row_border_color']['text'] != '' ? $SESSION['theme']['table_row_border_color']['text'] : '#c5d1e5').";\n";
+ echo " }\n";
+
echo "\n";
//new message layer
@@ -175,16 +180,17 @@
echo "\n";
echo " \n";
echo " | ".$text['label-contacts']." | \n";
- echo " ".$text['label-messages']." | \n";
+ echo " ".$text['label-messages']." | \n";
+ echo " | \n";
echo " \n";
echo " \n";
- echo " | ... | \n";
- echo " ... | \n";
+ echo " ··· | \n";
+ echo " ··· | \n";
echo " \n";
echo " \n";
- echo "
";
+ echo "\n";
- //js to load messages for clicked number
+//js to load messages for clicked number
echo "\n";
+ }
+ }
+ else {
+ echo escape(format_phone($number));
+ if ($selected) {
+ echo "\n";
+ }
}
echo " |
\n";
$c = $c == 0 ? 1 : 0;
diff --git a/app/messages/messages_thread.php b/app/messages/messages_thread.php
index 20e4fe310c..14d3d38b6e 100644
--- a/app/messages/messages_thread.php
+++ b/app/messages/messages_thread.php
@@ -149,7 +149,7 @@
echo "\n";
if (!$refresh) {
- echo "\n";
+ echo "
\n";
}
//output messages
@@ -191,6 +191,9 @@
echo "\n";
}
+ //set current contact
+ echo "\n";
+
if (!$refresh) {
echo "
\n";
@@ -208,9 +211,9 @@
echo "\n";
echo "
\n";
echo "\n";