From b04c50cf15c5e41220df8b3e01f2b3705265a911 Mon Sep 17 00:00:00 2001 From: mattf Date: Thu, 1 Sep 2022 03:08:01 +0000 Subject: [PATCH] More ConfBridge updates, doc and code git-svn-id: svn://192.168.202.10@3633 3d104415-ff17-0410-8863-d5cf3c621b8a --- extras/ConfBridge/AST_VDremote_agents.pl.diff | 4 +- .../ConfBridge/ConfBridge Documentation.txt | 11 +++-- extras/ConfBridge/non_agent_api.php.diff | 46 +++++++++++++++++++ 3 files changed, 54 insertions(+), 7 deletions(-) create mode 100644 extras/ConfBridge/non_agent_api.php.diff diff --git a/extras/ConfBridge/AST_VDremote_agents.pl.diff b/extras/ConfBridge/AST_VDremote_agents.pl.diff index 768d1322..3d96674a 100644 --- a/extras/ConfBridge/AST_VDremote_agents.pl.diff +++ b/extras/ConfBridge/AST_VDremote_agents.pl.diff @@ -1,5 +1,5 @@ --- AST_VDremote_agents.pl.old 2022-08-31 10:14:56.754198885 -0400 -+++ AST_VDremote_agents.pl 2022-08-31 10:14:32.350279855 -0400 ++++ AST_VDremote_agents.pl 2022-08-31 21:44:54.969475700 -0400 @@ -194,7 +194,7 @@ ########################################### @@ -21,7 +21,7 @@ { $TESTrun++; $DBremote_conf_exten[$user_counter] = ($user_counter + 8600051); -+ if ($conf_engine eq 'CONFBRIDGE') { $DBremote_conf_exten[$user_counter] = ($user_counter + 29600051); } ++ if ($conf_engine eq 'CONFBRIDGE') { $DBremote_conf_exten[$user_counter] = ($user_counter + 9600051); } } $DBremote_closer[$user_counter] = $closer_campaigns; $DBremote_random[$user_counter] = $random; diff --git a/extras/ConfBridge/ConfBridge Documentation.txt b/extras/ConfBridge/ConfBridge Documentation.txt index 620b17d5..dd07521b 100644 --- a/extras/ConfBridge/ConfBridge Documentation.txt +++ b/extras/ConfBridge/ConfBridge Documentation.txt @@ -50,13 +50,13 @@ The following extensions needed to be added to the Asterisk /etc/asterisk/extens exten => _49600XXX,n,ConfBridge(${EXTEN:1},vici_agent_bridge,vici_monitor_user) exten => _49600XXX,n,Hangup() - ; used to barge into a conference + ; used to record into a conference exten => _59600XXX,1,Answer() exten => _59600XXX,n,Playback(sip-silence) exten => _59600XXX,n,ConfBridge(${EXTEN:1},vici_agent_bridge,vici_recording_user) exten => _59600XXX,n,Hangup() - ; used to record a conference + ; used to barge a conference exten => _69600XXX,1,Answer() exten => _69600XXX,n,Playback(sip-silence) exten => _69600XXX,n,ConfBridge(${EXTEN:1},vici_agent_bridge,vici_barge_user) @@ -547,7 +547,7 @@ NOTE: The "AST_conf_update_screen.pl" script is a new perl script, not a patch f Here is the list of files for specific default directories: Dialers: -/usr/share/astguiclient - +/usr/share/astguiclient/ - - ADMIN_keepalive_ALL.pl.diff - ADMIN_update_server_ip.pl.diff - AST_DB_optimize.pl.diff @@ -556,11 +556,12 @@ Dialers: - AST_conf_update_screen.pl Webservers: -/srv/www/htdocs/agc - +/srv/www/htdocs/agc/ - - vicidial.php.diff - vdc_db_query.php.diff - manager_send.php.diff - +/srv/www/htdocs/vicidial/ - +- non_agent_api.php.diff - Web Admin changes: diff --git a/extras/ConfBridge/non_agent_api.php.diff b/extras/ConfBridge/non_agent_api.php.diff new file mode 100644 index 00000000..f1c64afe --- /dev/null +++ b/extras/ConfBridge/non_agent_api.php.diff @@ -0,0 +1,46 @@ +--- non_agent_api.php.old 2022-08-31 17:16:56.143133710 -0400 ++++ non_agent_api.php 2022-08-31 21:45:30.209365913 -0400 +@@ -195,6 +195,7 @@ + # 220310-0825 - Added DELETE action to the 'update_presets' function + # 220312-0944 - Added vicidial_dial_cid_log logging + # 220519-2206 - Small fix for 'update_lead' delete_lead feature ++# 200831-0758 - Added ConfBridge to BLIND_MONITOR + # + + $version = '2.14-172'; +@@ -2882,7 +2883,25 @@ + } + else + { +- $stmt="SELECT count(*) from vicidial_conferences where conf_exten='$session_id' and server_ip='$server_ip';"; ++ $stmt ="SELECT conf_engine from servers where server_ip='$server_ip';"; ++ $rslt=mysql_to_mysqli($stmt, $link); ++ $row=mysqli_fetch_row($rslt); ++ $conf_engine=$row[0]; ++ ++ if($conf_engine == "CONFBRIDGE") ++ { ++ $conf_table = "vicidial_confbridges"; ++ $monitor_prefix = '4'; ++ $barge_prefix = '6'; ++ } ++ else ++ { ++ $conf_table = "vicidial_conferences"; ++ $monitor_prefix = '0'; ++ $barge_prefix = ''; ++ } ++ ++ $stmt="SELECT count(*) from $conf_table where conf_exten='$session_id' and server_ip='$server_ip';"; + $rslt=mysql_to_mysqli($stmt, $link); + $row=mysqli_fetch_row($rslt); + $session_exists=$row[0]; +@@ -2948,7 +2967,7 @@ + $monitor_dialstring = "$D_s_ip[0]$S$D_s_ip[1]$S$D_s_ip[2]$S$D_s_ip[3]$S"; + + $monitor_type='LISTEN'; $cid_prefix='BM'; $swap_chan=0; +- if ( (preg_match('/MONITOR/',$stage)) or (strlen($stage)<1) ) {$stage = '0';} ++ if ( (preg_match('/MONITOR/',$stage)) or (strlen($stage)<1) ) {$stage = $monitor_prefix;} + if (preg_match('/BARGE/',$stage)) + { + if (preg_match('/SWAP/',$stage)) {$swap_chan=1;}