From 29fb8dd6bd34a7ff45cd88608d8a3c412902681d Mon Sep 17 00:00:00 2001 From: Nate Jones Date: Sat, 6 Sep 2014 07:43:51 +0000 Subject: [PATCH] Ring Group: Added ability to set Caller ID Number Prefix - Part 1 --- app/ring_groups/app_languages.php | 26 ++++++++++++++++++-------- app/ring_groups/ring_group_edit.php | 20 +++++++++++++++++--- 2 files changed, 35 insertions(+), 11 deletions(-) diff --git a/app/ring_groups/app_languages.php b/app/ring_groups/app_languages.php index d0c865485a..d588a76de7 100644 --- a/app/ring_groups/app_languages.php +++ b/app/ring_groups/app_languages.php @@ -56,10 +56,15 @@ $text['description']['fr-fr'] = "Un groupe de sonnerie est un groupe de destinations pouvant être appelé via une stratégie de sonnerie."; $text['description']['pt-pt'] = "Um grupo é um conjunto de destinos que podem ser chamados segunda uma determinada estratégia."; - $text['description-cid-prefix']['en-us'] = "Set a prefix on the caller ID name."; - $text['description-cid-prefix']['es-cl'] = "Indique un prefijo para el nombre de Caller ID"; - $text['description-cid-prefix']['fr-fr'] = "Choisir un préfixe pour le nom de l'appelant."; - $text['description-cid-prefix']['pt-pt'] = "Escolha um prefixo para o nome do originador da chamada."; + $text['description-cid-name-prefix']['en-us'] = "Set a prefix on the caller ID name."; + $text['description-cid-name-prefix']['es-cl'] = "Indique un prefijo para el nombre de Caller ID"; + $text['description-cid-name-prefix']['fr-fr'] = "Choisir un préfixe pour le nom de l'appelant."; + $text['description-cid-name-prefix']['pt-pt'] = "Escolha um prefixo para o nome do originador da chamada."; + + $text['description-cid-number-prefix']['en-us'] = "Set a prefix on the caller ID number."; + $text['description-cid-number-prefix']['es-cl'] = "Establezca un prefijo del número de identificación de llamadas."; + $text['description-cid-number-prefix']['fr-fr'] = "Définir un préfixe sur le nombre d'ID d'appelant."; + $text['description-cid-number-prefix']['pt-pt'] = "Definir um prefixo do número de identificação de chamadas."; $text['description-description']['en-us'] = "Enter a description (optional)."; $text['description-description']['es-cl'] = "Ingrese una descripción (opcional)"; @@ -141,10 +146,15 @@ $text['label-call-forward']['fr-fr'] = "Renvoi d'Appel:"; $text['label-call-forward']['pt-pt'] = "Encaminhar Chamada:"; - $text['label-cid-prefix']['en-us'] = "CID Prefix"; - $text['label-cid-prefix']['es-cl'] = "Prefijo CID"; - $text['label-cid-prefix']['fr-fr'] = "CID Préfixe"; - $text['label-cid-prefix']['pt-pt'] = "Prefixo CID"; + $text['label-cid-name-prefix']['en-us'] = "CID Name Prefix"; + $text['label-cid-name-prefix']['es-cl'] = "CID Nombre Prefijo"; + $text['label-cid-name-prefix']['fr-fr'] = "CID Préfixe de Nom"; + $text['label-cid-name-prefix']['pt-pt'] = "CID Prefixo do Nome"; + + $text['label-cid-number-prefix']['en-us'] = "CID Number Prefix"; + $text['label-cid-number-prefix']['es-cl'] = "Número CID Prefijo"; + $text['label-cid-number-prefix']['fr-fr'] = "CID Nombre Préfixe"; + $text['label-cid-number-prefix']['pt-pt'] = "CID Prefixo"; $text['label-context']['en-us'] = "Context"; $text['label-context']['es-cl'] = "Contexto"; diff --git a/app/ring_groups/ring_group_edit.php b/app/ring_groups/ring_group_edit.php index 77119c24f1..2a040c6325 100644 --- a/app/ring_groups/ring_group_edit.php +++ b/app/ring_groups/ring_group_edit.php @@ -77,6 +77,7 @@ else { $ring_group_strategy = check_str($_POST["ring_group_strategy"]); $ring_group_timeout_action = check_str($_POST["ring_group_timeout_action"]); $ring_group_cid_name_prefix = check_str($_POST["ring_group_cid_name_prefix"]); + $ring_group_cid_number_prefix = check_str($_POST["ring_group_cid_number_prefix"]); $ring_group_ringback = check_str($_POST["ring_group_ringback"]); $ring_group_skip_active = check_str($_POST["ring_group_skip_active"]); $ring_group_enabled = check_str($_POST["ring_group_enabled"]); @@ -144,7 +145,8 @@ else { if (strlen($ring_group_extension) == 0) { $msg .= $text['message-extension']."
\n"; } if (strlen($ring_group_strategy) == 0) { $msg .= $text['message-strategy']."
\n"; } //if (strlen($ring_group_timeout_app) == 0) { $msg .= $text['message-timeout-action']."
\n"; } - //if (strlen($ring_group_cid_name_prefix) == 0) { $msg .= "Please provide: Caller ID Prefix
\n"; } + //if (strlen($ring_group_cid_name_prefix) == 0) { $msg .= "Please provide: Caller ID Name Prefix
\n"; } + //if (strlen($ring_group_cid_number_prefix) == 0) { $msg .= "Please provide: Caller ID Number Prefix
\n"; } //if (strlen($ring_group_ringback) == 0) { $msg .= "Please provide: Ringback
\n"; } if (strlen($ring_group_enabled) == 0) { $msg .= $text['message-enabled']."
\n"; } //if (strlen($ring_group_description) == 0) { $msg .= "Please provide: Description
\n"; } @@ -326,6 +328,7 @@ else { $ring_group_timeout_app = $row["ring_group_timeout_app"]; $ring_group_timeout_data = $row["ring_group_timeout_data"]; $ring_group_cid_name_prefix = $row["ring_group_cid_name_prefix"]; + $ring_group_cid_number_prefix = $row["ring_group_cid_number_prefix"]; $ring_group_ringback = $row["ring_group_ringback"]; $ring_group_skip_active = $row["ring_group_skip_active"]; $ring_group_enabled = $row["ring_group_enabled"]; @@ -580,12 +583,23 @@ else { echo "\n"; echo "\n"; - echo " ".$text['label-cid-prefix'].":\n"; + echo " ".$text['label-cid-name-prefix'].":\n"; echo "\n"; echo "\n"; echo " \n"; echo "
\n"; - echo $text['description-cid-prefix']." \n"; + echo $text['description-cid-name-prefix']." \n"; + echo "\n"; + echo "\n"; + + echo "\n"; + echo "\n"; + echo " ".$text['label-cid-number-prefix'].":\n"; + echo "\n"; + echo "\n"; + echo " \n"; + echo "
\n"; + echo $text['description-cid-number-prefix']." \n"; echo "\n"; echo "\n";