diff --git a/app/call_block/app_languages.php b/app/call_block/app_languages.php
index bf329113ba..42845acfba 100644
--- a/app/call_block/app_languages.php
+++ b/app/call_block/app_languages.php
@@ -350,6 +350,31 @@ $text['label-busy']['de-at'] = "Besetzt";
$text['label-busy']['ar-eg'] = "مشغول";
$text['label-busy']['he'] = "תפוס";
+$text['label-hold']['en-us'] = "Hold";
+$text['label-hold']['es-cl'] = "";
+$text['label-hold']['pt-pt'] = "";
+$text['label-hold']['fr-fr'] = "";
+$text['label-hold']['nl-nl'] = "";
+$text['label-hold']['pt-br'] = "";
+$text['label-hold']['pl'] = "";
+$text['label-hold']['sv-se'] = "";
+$text['label-hold']['uk'] = "";
+$text['label-hold']['ro'] = "";
+$text['label-hold']['de-at'] = "";
+$text['label-hold']['ar-eg'] = "";
+$text['label-hold']['he'] = "";
+
+$text['label-voicemail']['en-us'] = "Voicemail";
+$text['label-voicemail']['es-cl'] = "Correo de Voz";
+$text['label-voicemail']['pt-pt'] = "Correio de Voz";
+$text['label-voicemail']['fr-fr'] = "Messagerie Vocale";
+$text['label-voicemail']['pt-br'] = "Correio de voz";
+$text['label-voicemail']['pl'] = "Poczta głosowa";
+$text['label-voicemail']['sv-se'] = "Röstbrevlåda";
+$text['label-voicemail']['uk'] = "Голосова пошта";
+$text['label-voicemail']['de-at'] = "Mailbox";
+$text['label-voicemail']['he'] = "תא קולי";
+
$text['label-add-note']['en-us'] = "Block calls from a number. Either select a number from the list above or enter the number, name and enable below.";
$text['label-add-note']['es-cl'] = "Bloquea llamadas desde un número. Puede elegir un número de la lista de arriba o ingresar el nú, nombre y activarlo abajo.";
$text['label-add-note']['pt-pt'] = "Bloquear chamadas a partir de um número. Seleccione um número a partir da lista indicada ou introduza um número, nome e active.";
diff --git a/app/call_block/call_block_edit.php b/app/call_block/call_block_edit.php
index d3591af4d3..b67fa81b57 100644
--- a/app/call_block/call_block_edit.php
+++ b/app/call_block/call_block_edit.php
@@ -298,6 +298,12 @@ if (count($_POST)>0 && strlen($_POST["persistformvar"]) == 0) {
else {
echo " \n";
}
+ if ($action == "Hold") {
+ echo " \n";
+ }
+ else {
+ echo " \n";
+ }
call_block_get_extensions($extension);
echo " \n";
echo " \n";
diff --git a/app/dialplan/resources/switch/conf/dialplan/040_call_block.xml b/app/dialplan/resources/switch/conf/dialplan/040_call_block.xml
index 2f76cf98b6..dfa876b8c8 100644
--- a/app/dialplan/resources/switch/conf/dialplan/040_call_block.xml
+++ b/app/dialplan/resources/switch/conf/dialplan/040_call_block.xml
@@ -1,7 +1,7 @@
-
-
+
+
\ No newline at end of file
diff --git a/resources/install/scripts/app/call_block/index.lua b/resources/install/scripts/app/call_block/index.lua
index 8821a099ef..f6b1a23d94 100644
--- a/resources/install/scripts/app/call_block/index.lua
+++ b/resources/install/scripts/app/call_block/index.lua
@@ -112,6 +112,7 @@ This method causes the script to get its manadatory arguments directly from the
--set the cache
if (found_cid_num) then -- caller id exists
if (found_enabled == "true") then
+ --set the cache
cache = "found_cid_num=" .. found_cid_num .. "&found_uuid=" .. found_uuid .. "&found_enabled=" .. found_enabled .. "&found_action=" .. found_action .. "&found_count=" .. found_count;
result = trim(api:execute("memcache", "set app:call_block:" .. params["domain_name"] .. ":" .. params["cid_num"] .. " '"..cache.."' "..expire["call_block"]));
@@ -172,7 +173,7 @@ This method causes the script to get its manadatory arguments directly from the
if (source == "database") then
dbh:query("UPDATE v_call_block SET call_block_count = " .. found_count + 1 .. " WHERE call_block_uuid = '" .. found_uuid .. "'")
end
- session:setVariable("call_block", "block")
+ session:execute("set", "call_blocked=true");
logger("W", "NOTICE", "number " .. params["cid_num"] .. " blocked with " .. found_count .. " previous hits, domain_name: " .. params["domain_name"])
if (found_action == "Reject") then
session:hangup("CALL_REJECTED")
@@ -180,6 +181,10 @@ This method causes the script to get its manadatory arguments directly from the
if (found_action == "Busy") then
session:hangup("USER_BUSY")
end
+ if (details[0] =="Hold") then
+ session:setAutoHangup(false)
+ session:execute("transfer", "*9664 XML " .. details[1])
+ end
if (details[0] =="Voicemail") then
session:setAutoHangup(false)
session:execute("transfer", "*99" .. details[2] .. " XML " .. details[1])