diff --git a/agc_2-X/trunk/agi/agi-VDAD_ALL_inbound.agi b/agc_2-X/trunk/agi/agi-VDAD_ALL_inbound.agi
index 40b5a50f..9e8d5720 100644
--- a/agc_2-X/trunk/agi/agi-VDAD_ALL_inbound.agi
+++ b/agc_2-X/trunk/agi/agi-VDAD_ALL_inbound.agi
@@ -236,6 +236,7 @@
# 191117-2156 - Fix for truncated extension issue #1193
# 200424-1044 - Fix for incorrect list_id logging
# 200624-0011 - Added options for Answer signal settings
+# 200708-1126 - Added some list override settings
#
$script = 'agi-VDAD_ALL_inbound.agi';
@@ -1779,6 +1780,26 @@ if ( ( ( ( ($hm < $ct_default_start) || ($hm > $ct_default_stop) ) && ($hm >= $c
}
if ($after_hours_action =~ /VOICEMAIL|VMAIL_NO_INST/)
{
+ # First, look for a list override for after-hours voicemail from the database
+ $inbound_after_hours_voicemail='';
+ $stmtA = "SELECT inbound_after_hours_voicemail FROM vicidial_lists where list_id='$list_id';";
+ $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr;
+ $sthA->execute or die "executing: $stmtA ", $dbhA->errstr;
+ $sthArows=$sthA->rows;
+ $dbhP=$dbhA; $mysql_count='02XXX'; $MEL_aff_rows=$sthArows; &mysql_error_logging;
+ if ($sthArows > 0)
+ {
+ @aryA = $sthA->fetchrow_array;
+ $inbound_after_hours_voicemail = $aryA[0];
+ }
+ $sthA->finish();
+
+ if (length($inbound_after_hours_voicemail) > 0)
+ {
+ if ($AGILOG) {$agi_string = "List Override for After Hours Voicemail set: $inbound_after_hours_voicemail($after_hours_voicemail) $list_id|$callerid"; &agi_output;}
+ $after_hours_voicemail = $inbound_after_hours_voicemail;
+ }
+
if ( ($channel_group =~ /AGENTDIRECT/i) && (length($agent_only) > 1) && ($after_hours_voicemail =~ /AGENTVMAIL/) )
{
### Grab user's voicemail ID from the database
@@ -6783,6 +6804,29 @@ if ( ($drop_timer > $DROP_TIME) || ($MCdrop_override > 0) )
$drop_seconds = $DROP_TIME;
}
+ # Look for a list override for drop voicemail from the database
+ if ($drop_action =~ /VOICEMAIL|VMAIL_NO_INST/)
+ {
+ $inbound_drop_voicemail='';
+ $stmtA = "SELECT inbound_drop_voicemail FROM vicidial_lists where list_id='$list_id';";
+ $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr;
+ $sthA->execute or die "executing: $stmtA ", $dbhA->errstr;
+ $sthArows=$sthA->rows;
+ $dbhP=$dbhA; $mysql_count='02XXX'; $MEL_aff_rows=$sthArows; &mysql_error_logging;
+ if ($sthArows > 0)
+ {
+ @aryA = $sthA->fetchrow_array;
+ $inbound_drop_voicemail = $aryA[0];
+ }
+ $sthA->finish();
+
+ if (length($inbound_drop_voicemail) > 0)
+ {
+ if ($AGILOG) {$agi_string = "List Override for Drop Voicemail set: $inbound_drop_voicemail($VDADvoicemail_ext) $list_id|$callerid"; &agi_output;}
+ $VDADvoicemail_ext = $inbound_drop_voicemail;
+ }
+ }
+
if ( ($channel_group =~ /AGENTDIRECT/i) && (length($agent_only) > 1) && ( (length($user_unavailable_action) > 1) || ($VDADvoicemail_ext =~ /AGENTVMAIL/) ) )
{
if ($VDADvoicemail_ext !~ /AGENTVMAIL/)
diff --git a/agc_2-X/trunk/extras/MySQL_AST_CREATE_tables.sql b/agc_2-X/trunk/extras/MySQL_AST_CREATE_tables.sql
index 9fda1b9d..d79fc62b 100644
--- a/agc_2-X/trunk/extras/MySQL_AST_CREATE_tables.sql
+++ b/agc_2-X/trunk/extras/MySQL_AST_CREATE_tables.sql
@@ -1083,7 +1083,9 @@ auto_active_list_rank SMALLINT(5) default '0',
cache_count INT(9) UNSIGNED default '0',
cache_count_new INT(9) UNSIGNED default '0',
cache_count_dialable_new INT(9) UNSIGNED default '0',
-cache_date DATETIME
+cache_date DATETIME,
+inbound_drop_voicemail VARCHAR(20),
+inbound_after_hours_voicemail VARCHAR(20)
) ENGINE=MyISAM;
CREATE TABLE vicidial_statuses (
@@ -4644,4 +4646,4 @@ INSERT INTO vicidial_settings_containers(container_id,container_notes,container_
UPDATE system_settings set vdc_agent_api_active='1';
-UPDATE system_settings SET db_schema_version='1599',db_schema_update_date=NOW(),reload_timestamp=NOW();
+UPDATE system_settings SET db_schema_version='1600',db_schema_update_date=NOW(),reload_timestamp=NOW();
diff --git a/agc_2-X/trunk/extras/upgrade_2.14.sql b/agc_2-X/trunk/extras/upgrade_2.14.sql
index 24e04e98..c5d984b1 100644
--- a/agc_2-X/trunk/extras/upgrade_2.14.sql
+++ b/agc_2-X/trunk/extras/upgrade_2.14.sql
@@ -1266,3 +1266,9 @@ UPDATE system_settings SET db_schema_version='1598',db_schema_update_date=NOW()
ALTER TABLE vicidial_campaigns MODIFY concurrent_transfers ENUM('AUTO','1','2','3','4','5','6','7','8','9','10','15','20','25','30','40','50','60','80','100','1000','10000') default 'AUTO';
UPDATE system_settings SET db_schema_version='1599',db_schema_update_date=NOW() where db_schema_version < 1599;
+
+ALTER TABLE vicidial_lists ADD inbound_drop_voicemail VARCHAR(20);
+ALTER TABLE vicidial_lists ADD inbound_after_hours_voicemail VARCHAR(20);
+
+UPDATE system_settings SET db_schema_version='1600',db_schema_update_date=NOW() where db_schema_version < 1600;
+
diff --git a/agc_2-X/trunk/www/vicidial/admin.php b/agc_2-X/trunk/www/vicidial/admin.php
index 6514d9bc..bd345957 100644
--- a/agc_2-X/trunk/www/vicidial/admin.php
+++ b/agc_2-X/trunk/www/vicidial/admin.php
@@ -2514,6 +2514,10 @@ if (isset($_GET["inbound_route_answer"])) {$inbound_route_answer=$_GET["inboun
elseif (isset($_POST["inbound_route_answer"])) {$inbound_route_answer=$_POST["inbound_route_answer"];}
if (isset($_GET["answer_signal"])) {$answer_signal=$_GET["answer_signal"];}
elseif (isset($_POST["answer_signal"])) {$answer_signal=$_POST["answer_signal"];}
+if (isset($_GET["inbound_drop_voicemail"])) {$inbound_drop_voicemail=$_GET["inbound_drop_voicemail"];}
+ elseif (isset($_POST["inbound_drop_voicemail"])) {$inbound_drop_voicemail=$_POST["inbound_drop_voicemail"];}
+if (isset($_GET["inbound_after_hours_voicemail"])) {$inbound_after_hours_voicemail=$_GET["inbound_after_hours_voicemail"];}
+ elseif (isset($_POST["inbound_after_hours_voicemail"])) {$inbound_after_hours_voicemail=$_POST["inbound_after_hours_voicemail"];}
if (isset($script_id)) {$script_id= strtoupper($script_id);}
@@ -3536,6 +3540,8 @@ if ($non_latin < 1)
$three_way_record_stop_exception = preg_replace('/[^-_0-9a-zA-Z]/','',$three_way_record_stop_exception);
$queuemetrics_pausereason = preg_replace('/[^-_0-9a-zA-Z]/','',$queuemetrics_pausereason);
$answer_signal = preg_replace('/[^-_0-9a-zA-Z]/','',$answer_signal);
+ $inbound_drop_voicemail = preg_replace('/[^-_0-9a-zA-Z]/','',$inbound_drop_voicemail);
+ $inbound_after_hours_voicemail = preg_replace('/[^-_0-9a-zA-Z]/','',$inbound_after_hours_voicemail);
### ALPHA-NUMERIC and underscore and dash and slash and dot
$menu_timeout_prompt = preg_replace('/[^-\/\|\._0-9a-zA-Z]/','',$menu_timeout_prompt);
@@ -4687,12 +4693,13 @@ else
# 200623-1957 - Added inbound answer configuration
# 200624-1939 - Added Callbacks Export report
# 200701-1525 - Added more concurrent_transfers options
+# 200708-1033 - Added List overrides for some inbound settings
#
# make sure you have added a user to the vicidial_users MySQL table with at least user_level 9 to access this page the first time
-$admin_version = '2.14-760a';
-$build = '200701-1525';
+$admin_version = '2.14-761a';
+$build = '200708-1033';
$STARTtime = date("U");
$SQLdate = date("Y-m-d H:i:s");
@@ -15852,7 +15859,7 @@ if ($ADD==411)
echo "
"._QXZ("LIST MODIFIED").": $list_id\n";
- $stmt="UPDATE vicidial_lists set list_name='$list_name',campaign_id='$campaign_id',active='$active',list_description='$list_description',list_changedate='$SQLdate',reset_time='$reset_time',agent_script_override='$agent_script_override',inbound_list_script_override='$inbound_list_script_override',campaign_cid_override='$campaign_cid_override',am_message_exten_override='$am_message_exten_override',drop_inbound_group_override='$drop_inbound_group_override',xferconf_a_number='$xferconf_a_number',xferconf_b_number='$xferconf_b_number',xferconf_c_number='$xferconf_c_number',xferconf_d_number='$xferconf_d_number',xferconf_e_number='$xferconf_e_number',web_form_address='" . mysqli_real_escape_string($link, $web_form_address) . "',web_form_address_two='" . mysqli_real_escape_string($link, $web_form_address_two) . "',time_zone_setting='$time_zone_setting',inventory_report='$inventory_report',expiration_date='$expiration_date',na_call_url='" . mysqli_real_escape_string($link, $na_call_url) . "',local_call_time='$local_call_time',web_form_address_three='" . mysqli_real_escape_string($link, $web_form_address_three) . "',status_group_id='$status_group_id',user_new_lead_limit='$user_new_lead_limit',default_xfer_group='$default_xfer_group' $daily_reset_limitSQL,auto_active_list_rank='$auto_active_list_rank' where list_id='$list_id';";
+ $stmt="UPDATE vicidial_lists set list_name='$list_name',campaign_id='$campaign_id',active='$active',list_description='$list_description',list_changedate='$SQLdate',reset_time='$reset_time',agent_script_override='$agent_script_override',inbound_list_script_override='$inbound_list_script_override',campaign_cid_override='$campaign_cid_override',am_message_exten_override='$am_message_exten_override',drop_inbound_group_override='$drop_inbound_group_override',xferconf_a_number='$xferconf_a_number',xferconf_b_number='$xferconf_b_number',xferconf_c_number='$xferconf_c_number',xferconf_d_number='$xferconf_d_number',xferconf_e_number='$xferconf_e_number',web_form_address='" . mysqli_real_escape_string($link, $web_form_address) . "',web_form_address_two='" . mysqli_real_escape_string($link, $web_form_address_two) . "',time_zone_setting='$time_zone_setting',inventory_report='$inventory_report',expiration_date='$expiration_date',na_call_url='" . mysqli_real_escape_string($link, $na_call_url) . "',local_call_time='$local_call_time',web_form_address_three='" . mysqli_real_escape_string($link, $web_form_address_three) . "',status_group_id='$status_group_id',user_new_lead_limit='$user_new_lead_limit',default_xfer_group='$default_xfer_group' $daily_reset_limitSQL,auto_active_list_rank='$auto_active_list_rank',inbound_drop_voicemail='$inbound_drop_voicemail',inbound_after_hours_voicemail='$inbound_after_hours_voicemail' where list_id='$list_id';";
$rslt=mysql_to_mysqli($stmt, $link);
## QC Addition for Audited Comments
@@ -27819,7 +27826,7 @@ if ($ADD==311)
}
}
- $stmt="SELECT vicidial_lists.list_id,list_name,campaign_id,active,list_description,list_changedate,list_lastcalldate,reset_time,agent_script_override,campaign_cid_override,am_message_exten_override,drop_inbound_group_override,xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,time_zone_setting,inventory_report,IFNULL(audit_comments,0),expiration_date,DATE_FORMAT(expiration_date,'%Y%m%d'),na_call_url,local_call_time,web_form_address_three,status_group_id,user_new_lead_limit,inbound_list_script_override,default_xfer_group,daily_reset_limit,resets_today,auto_active_list_rank from vicidial_lists left outer join vicidial_lists_custom on vicidial_lists.list_id=vicidial_lists_custom.list_id where vicidial_lists.list_id='$list_id' $LOGallowed_campaignsSQL;";
+ $stmt="SELECT vicidial_lists.list_id,list_name,campaign_id,active,list_description,list_changedate,list_lastcalldate,reset_time,agent_script_override,campaign_cid_override,am_message_exten_override,drop_inbound_group_override,xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,time_zone_setting,inventory_report,IFNULL(audit_comments,0),expiration_date,DATE_FORMAT(expiration_date,'%Y%m%d'),na_call_url,local_call_time,web_form_address_three,status_group_id,user_new_lead_limit,inbound_list_script_override,default_xfer_group,daily_reset_limit,resets_today,auto_active_list_rank,inbound_drop_voicemail,inbound_after_hours_voicemail from vicidial_lists left outer join vicidial_lists_custom on vicidial_lists.list_id=vicidial_lists_custom.list_id where vicidial_lists.list_id='$list_id' $LOGallowed_campaignsSQL;";
$rslt=mysql_to_mysqli($stmt, $link);
if ($DB) {echo "$stmt\n";}
@@ -27857,6 +27864,8 @@ if ($ADD==311)
$daily_reset_limit = $row[31];
$resets_today = $row[32];
$auto_active_list_rank = $row[33];
+ $inbound_drop_voicemail = $row[34];
+ $inbound_after_hours_voicemail = $row[35];
# grab names of global statuses and statuses in the selected campaign
$stmt="SELECT status,status_name,selectable,human_answered,category,sale,dnc,customer_contact,not_interested,unworkable,scheduled_callback,completed,min_sec,max_sec,answering_machine from vicidial_statuses order by status;";
@@ -28032,6 +28041,8 @@ if ($ADD==311)
echo "$Lscripts_list";
echo "\n";
echo "$NWB#lists-inbound_list_script_override$NWE\n";
+ echo "