From 688f6b535723ddb19d9ffb2c61d161add6fa94b8 Mon Sep 17 00:00:00 2001 From: mattf Date: Thu, 17 Sep 2009 00:50:45 +0000 Subject: [PATCH] Added second web form option for in-groups and campaigns Changed answering machine message to a prompt field and added TTS option Added waitforsilence options to campaign screen git-svn-id: svn://192.168.202.10@1228 3d104415-ff17-0410-8863-d5cf3c621b8a --- agc_2-X/trunk/UPGRADE | 14 + agc_2-X/trunk/agi/VD_amd.agi | 609 +++++++++++------- agc_2-X/trunk/agi/VD_amd_post.agi | 4 +- agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi | 3 +- .../docs/conf_examples/extensions.conf.sample | 7 +- .../conf_examples/extensions.conf.sample-1.4 | 7 +- .../trunk/extras/MySQL_AST_CREATE_tables.sql | 19 +- agc_2-X/trunk/extras/upgrade_2.2.0.sql | 14 + .../TO_BE_TRANSLATED_2.2.0.txt | 7 + .../www/agc/images/vdc_LB_webform_two.gif | Bin 0 -> 571 bytes .../www/agc/images/vdc_LB_webform_two_OFF.gif | Bin 0 -> 565 bytes agc_2-X/trunk/www/agc/manager_send.php | 34 +- agc_2-X/trunk/www/agc/vdc_db_query.php | 41 +- agc_2-X/trunk/www/agc/vicidial.php | 369 ++++++++++- agc_2-X/trunk/www/vicidial/admin.php | 84 ++- 15 files changed, 892 insertions(+), 320 deletions(-) create mode 100644 agc_2-X/trunk/www/agc/images/vdc_LB_webform_two.gif create mode 100644 agc_2-X/trunk/www/agc/images/vdc_LB_webform_two_OFF.gif diff --git a/agc_2-X/trunk/UPGRADE b/agc_2-X/trunk/UPGRADE index 8a4be09a..01e27e3b 100644 --- a/agc_2-X/trunk/UPGRADE +++ b/agc_2-X/trunk/UPGRADE @@ -222,6 +222,20 @@ NOTE: Upgrading from 1.1.12-3 to 2.0.1 is at the bottom 57. Added DEAD call time logging and agent notification of call hangup +58. Added second web form button with different URLs possible per campaign and + in-group. Must be enabled in System Settings + +59. Changed Answering Machine Message campaign option to an audio select with an + option for TTS prompt to be used. You must change any custom values you + have set in this field to an audio prompt or it will not function + properly. Also added WaitForSilence Options setting to the campaign + screen. If you want to use this it must be populated in each campaign. + + You must change 8320 to the following in your extensions.conf: + exten => 8320,1,AGI(VD_amd.agi,${EXTEN}-----YES) + exten => 8320,2,Hangup + # the VD_amd_post.agi script is now depricated + diff --git a/agc_2-X/trunk/agi/VD_amd.agi b/agc_2-X/trunk/agi/VD_amd.agi index 1b467b64..42d07cf7 100644 --- a/agc_2-X/trunk/agi/VD_amd.agi +++ b/agc_2-X/trunk/agi/VD_amd.agi @@ -1,24 +1,25 @@ #!/usr/bin/perl # -# VD_amd.agi version 2.0.4 *DBI-version* +# VD_amd.agi version 2.2.0 *DBI-version* # -# NOTE: This script is only needed with app_amd enabled systems -# # runs after a call goes through AMD in extensions.conf to send the call on to -# it's proper destination +# it's proper destination, or when agent sends to VM message # # You need to put lines similar to those below in your extensions.conf file: # # ; VICIDIAL_auto_dialer transfer script AMD with Load Balanced: # exten => 8369,1,AGI(call_log.agi,${EXTEN}) # exten => 8369,2,(AMD),AMD -# exten => 8369,3,AGI(VD_amd.agi,${EXTEN}) +# exten => 8369,3,AGI(VD_amd.agi,${EXTEN}-----NO) # exten => 8369,4,AGI(agi-VDAD_LB_transfer.agi,${EXTEN}) # exten => 8369,5,AGI(agi-VDAD_LB_transfer.agi,${EXTEN}) # exten => 8369,6,AGI(agi-VDAD_LB_transfer.agi,${EXTEN}) # exten => 8369,7,Hangup # -# Copyright (C) 2007 Matt Florell LICENSE: AGPLv2 +# exten => 8320,1,AGI(VD_amd.agi,${EXTEN}-----YES) +# exten => 8320,2,Hangup +# +# Copyright (C) 2009 Matt Florell LICENSE: AGPLv2 # # changes: # 60206-1434 first build @@ -28,6 +29,7 @@ # - changed to use /etc/astguiclient.conf for configs # 60815-1310 - added output options check from database # 71118-0252 - compatibility with Asterisk 1.4, added AA and AM statuses +# 90916-1317 - Changed to audio file playback and TTS playback # $script = 'VD_amd.agi'; @@ -85,8 +87,9 @@ foreach(@conf) $i++; } -if (!$VARDB_port) {$VARDB_port='3306';} -if (!$AGILOGfile) {$AGILOGfile = "$PATHlogs/agiout.$year-$mon-$mday";} +if (!$VARDB_port) {$VARDB_port='3306';} +if (!$AGILOGfile) {$AGILOGfile = "$PATHlogs/agiout.$year-$mon-$mday";} +if (!$CEPLOGfile) {$CEPLOGfile = "$PATHlogs/Cepstral.$year-$mon-$mday";} use DBI; use Asterisk::AGI; @@ -105,72 +108,48 @@ $rec_count=0; while ($sthArows > $rec_count) { $AGILOG = '0'; - @aryA = $sthA->fetchrow_array; - $DBagi_output = "$aryA[0]"; - if ($DBagi_output =~ /STDERR/) {$AGILOG = '1';} - if ($DBagi_output =~ /FILE/) {$AGILOG = '2';} - if ($DBagi_output =~ /BOTH/) {$AGILOG = '3';} - $rec_count++; + @aryA = $sthA->fetchrow_array; + $DBagi_output = "$aryA[0]"; + if ($DBagi_output =~ /STDERR/) {$AGILOG = '1';} + if ($DBagi_output =~ /FILE/) {$AGILOG = '2';} + if ($DBagi_output =~ /BOTH/) {$AGILOG = '3';} + $rec_count++; } $sthA->finish(); ### begin parsing run-time options ### if (length($ARGV[0])>1) -{ - if ($AGILOG) {$agi_string = "Perl Environment Dump:"; &agi_output;} + { + if ($AGILOG) + {$agi_string = "Perl Environment Dump:"; &agi_output;} $i=0; while ($#ARGV >= $i) - { - $args = "$args $ARGV[$i]"; - if ($AGILOG) {$agi_string = "$i|$ARGV[$i]"; &agi_output;} - $i++; + { + $args = "$args $ARGV[$i]"; + if ($AGILOG) {$agi_string = "$i|$ARGV[$i]"; &agi_output;} + $i++; + } + + ### list of command-line array arguments: + @ARGV_vars = split(/-----/, $ARGV[0]); + $CLI_exten = $ARGV_vars[0]; + $force_playback = $ARGV_vars[1]; } - if ($args =~ /--help/i) - { - print "allowed run time options:\n [-q] = quiet\n [-t] = test\n [-debug] = verbose debug messages\n\n"; - } - else - { - if ($args =~ /-V/i) - { - $V=1; - } - if ($args =~ /-debug/i) - { - $DG=1; - } - if ($args =~ /-dbAVS/i) - { - $DGA=1; - } - if ($args =~ /-q/i) - { - $q=1; - $Q=1; - } - if ($args =~ /-t/i) - { - $TEST=1; - $T=1; - } - } -} - $|=1; while() -{ + { chomp; last unless length($_); if ($AGILOG) - { - if (/^agi_(\w+)\:\s+(.*)$/) { + if (/^agi_(\w+)\:\s+(.*)$/) + { $AGI{$1} = $2; + } } - } if (/^agi_uniqueid\:\s+(.*)$/) {$unique_id = $1; $uniqueid = $unique_id;} if (/^agi_priority\:\s+(.*)$/) {$priority = $1;} @@ -179,36 +158,35 @@ while() if (/^agi_type\:\s+(.*)$/) {$type = $1;} if (/^agi_callerid\:\s+(.*)$/) {$callerid = $1; $calleridnum = $callerid;} if (/^agi_calleridname\:\s+(.*)$/) {$calleridname = $1;} -} + } if ( (length($callerid)>20) && ($callerid =~ /\"\S\S\S\S\S\S\S\S\S\S\S\S\S\S\S\S\S\S/) ) - { - $callerid =~ s/^\"//gi; - $callerid =~ s/\".*$//gi; + { + $callerid =~ s/^\"//gi; + $callerid =~ s/\".*$//gi; # ### set the callerid to the ACQS value(calleridname) # print "SET CALLERID $callerid\n"; # checkresult($result); # print STDERR "callerID changed: $callerid\n"; - - } + } if ( ( (length($calleridname)>5) && ( (!$callerid) or ($callerid =~ /unknown|private|00000000/i) or ($callerid =~ /5551212/) ) ) or ( (length($calleridname)>17) && ($calleridname =~ /\d\d\d\d\d\d\d\d\d\d\d\d\d\d\d\d\d\d\d/) ) ) - { - $callerid = $calleridname; + { + $callerid = $calleridname; # ### set the callerid to the ACQS value(calleridname) # print "SET CALLERID $callerid\n"; # checkresult($result); # print STDERR "callerID changed: $callerid\n"; - } + } if ($AGILOG) {$agi_string = "AGI Environment Dump:"; &agi_output;} foreach $i (sort keys %AGI) -{ + { if ($AGILOG) {$agi_string = " -- $i = $AGI{$i}"; &agi_output;} -} + } if ($AGILOG) {$agi_string = "AGI Variables: |$unique_id|$channel|$extension|$type|$callerid|"; &agi_output;} @@ -227,21 +205,20 @@ if ($AGILOG) {$agi_string = "+++++ VD amd START : |$CIDlead_id|$now_date|$AST_ve if ( ($channel =~ /Local/i) && ($AST_ver !~ /^1\.0\.8|^1\.0\.9/) ) -{ -if ($AGILOG) {$agi_string = "+++++ VDAD START LOCAL CHANNEL: EXITING- $priority"; &agi_output;} -if ($priority > 2) {sleep(1);} -exit; -} + { + if ($AGILOG) {$agi_string = "+++++ VDAD START LOCAL CHANNEL: EXITING- $priority"; &agi_output;} + if ($priority > 2) {sleep(1);} + exit; + } - -$AMDSTATUS = $AGI->get_variable(AMDSTATUS); +$AMDSTATUS = $AGI->get_variable(AMDSTATUS); $AMDCAUSE = $AGI->get_variable(AMDCAUSE); -if ($A) -{ -if ($AGILOG) {$agi_string = "AAAAA AMD results: |$AMDSTATUS|$AMDCAUSE|"; &agi_output;} -} +if ($A) + { + if ($AGILOG) {$agi_string = "AAAAA AMD results: |$AMDSTATUS|$AMDCAUSE|"; &agi_output;} + } # Asterisk 1.2.X # AAAAA AMD results: |AMD_PERSON|AMD_HUMAN-300-300| @@ -261,148 +238,311 @@ if ($AMD_LOG) ################################################################################## ########## AMD says it's a person so exit and go on to transfer scripts ########## -if ($AMDSTATUS =~ /PERSON|HUMAN|NOTSURE|HANGUP/) -{ +if ( ($AMDSTATUS =~ /PERSON|HUMAN|NOTSURE|HANGUP/) && ($force_playback !~ /YES/) ) + { if ($A) - { - if ($AGILOG) {$agi_string = " AMD exiting"; &agi_output;} - } - exit; -} - -else -{ -################################################################################ -########## AMD says it's a machine so modify statuses and hangup call ########## -########## something will go here later for leaving a message on AMs ########## - - -########## FIND ext_context from the servers table ########## -$stmtA = "SELECT ext_context FROM servers where server_ip = '$VARserver_ip';"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} -$sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; -$sthA->execute or die "executing: $stmtA ", $dbhA->errstr; -$sthArows=$sthA->rows; - $rec_count=0; -while ($sthArows > $rec_count) - { - @aryA = $sthA->fetchrow_array; - $DBext_context = "$aryA[0]"; - if ($DBext_context) {$ext_context = $DBext_context;} - $rec_count++; - } -$sthA->finish(); - - -########## FIND vicidial_auto_calls record ########## -$stmtA = "SELECT campaign_id,phone_code,phone_number FROM vicidial_auto_calls where callerid='$callerid' order by auto_call_id desc limit 1;"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} -$sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; -$sthA->execute or die "executing: $stmtA ", $dbhA->errstr; -$sthArows=$sthA->rows; - $rec_count=0; -while ($sthArows > $rec_count) - { - @aryA = $sthA->fetchrow_array; - $VD_campaign_id = "$aryA[0]"; - $VD_phone_code = "$aryA[1]"; - $VD_phone_number = "$aryA[2]"; - $rec_count++; - } -$sthA->finish(); - - -########## UPDATE vicidial_list ########## -$stmtA = "UPDATE vicidial_list set status='AA' where lead_id = '$VD_lead_id';"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} - $affected_rows = $dbhA->do($stmtA); -if ($AGILOG) {$agi_string = "-- VDAD vicidial_list update: |$affected_rows|$VD_lead_id"; &agi_output;} - -########## DELETE vicidial_auto_calls entry ########## -$stmtA = "DELETE FROM vicidial_auto_calls where callerid='$callerid' order by auto_call_id desc limit 1;"; - $affected_rows = $dbhA->do($stmtA); -if ($AGILOG) {$agi_string = "-- VDAC record deleted: |$affected_rows| |$VD_lead_id|$uniqueid|$VD_callerid"; &agi_output;} - -########## FIND AND UPDATE vicidial_log ########## -$stmtA = "SELECT start_epoch FROM vicidial_log where uniqueid='$uniqueid' and lead_id='$VD_lead_id' order by call_date desc limit 1;"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} -$sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; -$sthA->execute or die "executing: $stmtA ", $dbhA->errstr; -$sthArows=$sthA->rows; - $epc_countCUSTDATA=0; -while ($sthArows > $epc_countCUSTDATA) - { - @aryA = $sthA->fetchrow_array; - $VD_start_epoch = "$aryA[0]"; - $epc_countCUSTDATA++; - } -$sthA->finish(); - -if (!$epc_countCUSTDATA) - { - if ($AGILOG) {$agi_string = "no VDL record found: $uniqueid $calleridname $VD_lead_id $uniqueid"; &agi_output;} - $end_epoch = ($now_date_epoch + 3); - $stmtA = "INSERT INTO vicidial_log (uniqueid,lead_id,campaign_id,call_date,start_epoch,status,phone_code,phone_number,user,processed,length_in_sec,end_epoch) values('$uniqueid','$VD_lead_id','$VD_campaign_id','$now_date','$now_date_epoch','AA','$VD_phone_code','$VD_phone_number','VDAD','N','3','$end_epoch')"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} - $affected_rows = $dbhA->do($stmtA); - } -else - { - $VD_seconds = ($now_date_epoch - $VD_start_epoch); - $stmtA = "UPDATE vicidial_log set status='AA',end_epoch='$now_date_epoch',length_in_sec='$VD_seconds' where uniqueid='$uniqueid' and lead_id='$VD_lead_id' order by call_date desc limit 1;"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} - $affected_rows = $dbhA->do($stmtA); - if ($AGILOG) {$agi_string = "-- VDAD vicidial_log update: |$affected_rows|$uniqueid|"; &agi_output;} - } - - -### Grab vmail forward message values from the database -$stmtA = "SELECT am_message_exten,amd_send_to_vmx FROM vicidial_campaigns where campaign_id = '$VD_campaign_id';"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} -$sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; -$sthA->execute or die "executing: $stmtA ", $dbhA->errstr; -$sthArows=$sthA->rows; - $epc_countCUSTDATA=0; -while ($sthArows > $epc_countCUSTDATA) - { - @aryA = $sthA->fetchrow_array; - $DB_am_message_exten = "$aryA[0]"; - $DB_amd_send_to_vmx = "$aryA[1]"; - $epc_countCUSTDATA++; - } -$sthA->finish(); - -if ($AGILOG) {$agi_string = "-- AMD campaign values: |$VD_campaign_id|$DB_am_message_exten|$DB_amd_send_to_vmx|"; &agi_output;} - -if ( ($DB_amd_send_to_vmx =~ /Y/) && (length($DB_am_message_exten) > 0) ) - { - $stmtA = "UPDATE vicidial_log set status='AM' where uniqueid='$uniqueid' and lead_id='$VD_lead_id' order by call_date desc limit 1;"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} - $affected_rows = $dbhA->do($stmtA); - if ($AGILOG) {$agi_string = "-- VDAD vicidial_log AM update: |$affected_rows|$uniqueid|"; &agi_output;} - - $stmtA = "UPDATE vicidial_list set status='AM' where lead_id='$VD_lead_id';"; - if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} - $affected_rows = $dbhA->do($stmtA); - if ($AGILOG) {$agi_string = "-- VDAD vicidial_list AM update: |$affected_rows|$uniqueid|"; &agi_output;} - - if ($AGILOG) {$agi_string = "exiting the AMD app, transferring call to $DB_am_message_exten"; &agi_output;} - print "SET CONTEXT $ext_context\n"; - checkresult($result); - print "SET EXTENSION $DB_am_message_exten\n"; - checkresult($result); - print "SET PRIORITY 1\n"; - checkresult($result); - + { + if ($AGILOG) {$agi_string = " AMD exiting"; &agi_output;} + } exit; } -$dbhA->disconnect(); +else + { + ################################################################################ + ########## AMD says it's a machine so modify statuses and hangup call ########## + ########## or play back a message on AMs ########## -$AGI->hangup($channel); + $AGI->stream_file('sip-silence'); + $AGI->stream_file('sip-silence'); -exit; -} + + ########## FIND ext_context from the servers table ########## + $stmtA = "SELECT ext_context FROM servers where server_ip = '$VARserver_ip';"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; + $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; + $sthArows=$sthA->rows; + $rec_count=0; + while ($sthArows > $rec_count) + { + @aryA = $sthA->fetchrow_array; + $DBext_context = "$aryA[0]"; + if ($DBext_context) {$ext_context = $DBext_context;} + $rec_count++; + } + $sthA->finish(); + + + ########## FIND vicidial_auto_calls record ########## + $stmtA = "SELECT campaign_id,phone_code,phone_number FROM vicidial_auto_calls where callerid='$callerid' order by auto_call_id desc limit 1;"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; + $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; + $sthArows=$sthA->rows; + $rec_count=0; + while ($sthArows > $rec_count) + { + @aryA = $sthA->fetchrow_array; + $VD_campaign_id = "$aryA[0]"; + $VD_phone_code = "$aryA[1]"; + $VD_phone_number = "$aryA[2]"; + $rec_count++; + } + $sthA->finish(); + + + ########## UPDATE vicidial_list ########## + $stmtA = "UPDATE vicidial_list set status='AA' where lead_id = '$VD_lead_id';"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $affected_rows = $dbhA->do($stmtA); + if ($AGILOG) {$agi_string = "-- VDAD vicidial_list update: |$affected_rows|$VD_lead_id"; &agi_output;} + + ########## DELETE vicidial_auto_calls entry ########## + $stmtA = "DELETE FROM vicidial_auto_calls where callerid='$callerid' order by auto_call_id desc limit 1;"; + $affected_rows = $dbhA->do($stmtA); + if ($AGILOG) {$agi_string = "-- VDAC record deleted: |$affected_rows| |$VD_lead_id|$uniqueid|$VD_callerid"; &agi_output;} + + ########## FIND AND UPDATE vicidial_log ########## + $stmtA = "SELECT start_epoch FROM vicidial_log where uniqueid='$uniqueid' and lead_id='$VD_lead_id' order by call_date desc limit 1;"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; + $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; + $sthArows=$sthA->rows; + $epc_countCUSTDATA=0; + while ($sthArows > $epc_countCUSTDATA) + { + @aryA = $sthA->fetchrow_array; + $VD_start_epoch = "$aryA[0]"; + $epc_countCUSTDATA++; + } + $sthA->finish(); + + if (!$epc_countCUSTDATA) + { + if ($AGILOG) {$agi_string = "no VDL record found: $uniqueid $calleridname $VD_lead_id $uniqueid"; &agi_output;} + $end_epoch = ($now_date_epoch + 3); + $stmtA = "INSERT INTO vicidial_log (uniqueid,lead_id,campaign_id,call_date,start_epoch,status,phone_code,phone_number,user,processed,length_in_sec,end_epoch) values('$uniqueid','$VD_lead_id','$VD_campaign_id','$now_date','$now_date_epoch','AA','$VD_phone_code','$VD_phone_number','VDAD','N','3','$end_epoch')"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $affected_rows = $dbhA->do($stmtA); + } + else + { + $VD_seconds = ($now_date_epoch - $VD_start_epoch); + $stmtA = "UPDATE vicidial_log set status='AA',end_epoch='$now_date_epoch',length_in_sec='$VD_seconds' where uniqueid='$uniqueid' and lead_id='$VD_lead_id' order by call_date desc limit 1;"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $affected_rows = $dbhA->do($stmtA); + if ($AGILOG) {$agi_string = "-- VDAD vicidial_log update: |$affected_rows|$uniqueid|"; &agi_output;} + } + + + ### Grab vmail forward message values from the database + $stmtA = "SELECT am_message_exten,amd_send_to_vmx,waitforsilence_options FROM vicidial_campaigns where campaign_id = '$VD_campaign_id' limit 1;"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; + $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; + $sthArows=$sthA->rows; + if ($sthArows > 0) + { + @aryA = $sthA->fetchrow_array; + $DB_am_message_exten = $aryA[0]; + $DB_amd_send_to_vmx = $aryA[1]; + $waitforsilence_options = $aryA[2]; + $sthA->finish(); + } + else + { + $sthA->finish(); + ### Grab vmail forward message values from the database + $stmtA = "SELECT am_message_exten,amd_send_to_vmx,waitforsilence_options FROM vicidial_campaigns where closer_campaigns LIKE \"% $VD_campaign_id %\" order by campaign_id limit 1;"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; + $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; + $sthArows=$sthA->rows; + if ($sthArows > 0) + { + @aryA = $sthA->fetchrow_array; + $DB_am_message_exten = $aryA[0]; + $DB_amd_send_to_vmx = $aryA[1]; + $waitforsilence_options = $aryA[2]; + $sthA->finish(); + } + else + {$sthA->finish();} + } + if ($AGILOG) {$agi_string = "-- AMD campaign values: |$VD_campaign_id|$DB_am_message_exten|$DB_amd_send_to_vmx|"; &agi_output;} + + if ( ( ($DB_amd_send_to_vmx =~ /Y/) || ($force_playback =~ /YES/) ) && (length($DB_am_message_exten) > 0) ) + { + $stmtA = "UPDATE vicidial_log set status='AM' where uniqueid='$uniqueid' and lead_id='$VD_lead_id' order by call_date desc limit 1;"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $affected_rows = $dbhA->do($stmtA); + if ($AGILOG) {$agi_string = "-- VDAD vicidial_log AM update: |$affected_rows|$uniqueid|"; &agi_output;} + + $stmtA = "UPDATE vicidial_list set status='AM' where lead_id='$VD_lead_id';"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $affected_rows = $dbhA->do($stmtA); + if ($AGILOG) {$agi_string = "-- VDAD vicidial_list AM update: |$affected_rows|$uniqueid|"; &agi_output;} + + + ##### BEGIN Check if prompt uses TTS, if so, create TTS and set the filename to the generated prompt ##### + if ($DB_am_message_exten =~ /^TTS/) + { + $TTS_filename = $DB_am_message_exten; + $TTS_filename =~s/^TTS//gi; + $TTS_filename =~s/\|.*//gi; + + if ($AGILOG) {$agi_string = "-- TTS : |$TTS_filename|"; &agi_output;} + + $stmtA = "SELECT lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner FROM vicidial_list where lead_id='$VD_lead_id';"; + $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; + $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; + $sthArows=$sthA->rows; + if ($sthArows > 0) + { + @aryA = $sthA->fetchrow_array; + $TTS_lead_id = $aryA[0]; + $TTS_entry_date = $aryA[1]; + $TTS_modify_date = $aryA[2]; + $TTS_status = $aryA[3]; + $TTS_user = $aryA[4]; + $TTS_vendor_lead_code = $aryA[5]; + $TTS_source_id = $aryA[6]; + $TTS_list_id = $aryA[7]; + $TTS_phone_number = $aryA[8]; + $TTS_title = $aryA[9]; + $TTS_first_name = $aryA[10]; + $TTS_middle_initial = $aryA[11]; + $TTS_last_name = $aryA[12]; + $TTS_address1 = $aryA[13]; + $TTS_address2 = $aryA[14]; + $TTS_address3 = $aryA[15]; + $TTS_city = $aryA[16]; + $TTS_state = $aryA[17]; + $TTS_province = $aryA[18]; + $TTS_postal_code = $aryA[19]; + $TTS_country_code = $aryA[20]; + $TTS_gender = $aryA[21]; + $TTS_date_of_birth = $aryA[22]; + $TTS_alt_phone = $aryA[23]; + $TTS_email = $aryA[24]; + $TTS_security_phrase = $aryA[25]; + $TTS_comments = $aryA[26]; + $TTS_called_count = $aryA[27]; + $TTS_last_local_call_time = $aryA[28]; + $TTS_rank = $aryA[29]; + $TTS_owner = $aryA[30]; + } + $sthA->finish(); + + $stmtA = "SELECT tts_text FROM vicidial_tts_prompts where tts_id='$TTS_filename';"; + $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; + $sthA->execute or die "executing: $stmtA ", $dbhA->errstr; + $sthArows=$sthA->rows; + if ($sthArows > 0) + { + @aryA = $sthA->fetchrow_array; + $TTS_text = $aryA[0]; + $TTS_text =~ s/--A--lead_id--B--/$TTS_lead_id/gi; + $TTS_text =~ s/--A--entry_date--B--/$TTS_entry_date/gi; + $TTS_text =~ s/--A--modify_date--B--/$TTS_modify_date/gi; + $TTS_text =~ s/--A--status--B--/$TTS_status/gi; + $TTS_text =~ s/--A--user--B--/$TTS_user/gi; + $TTS_text =~ s/--A--vendor_lead_code--B--/$TTS_vendor_lead_code/gi; + $TTS_text =~ s/--A--source_id--B--/$TTS_source_id/gi; + $TTS_text =~ s/--A--list_id--B--/$TTS_list_id/gi; + $TTS_text =~ s/--A--phone_number--B--/$TTS_phone_number/gi; + $TTS_text =~ s/--A--title--B--/$TTS_title/gi; + $TTS_text =~ s/--A--first_name--B--/$TTS_first_name/gi; + $TTS_text =~ s/--A--middle_initial--B--/$TTS_middle_initial/gi; + $TTS_text =~ s/--A--last_name--B--/$TTS_last_name/gi; + $TTS_text =~ s/--A--address1--B--/$TTS_address1/gi; + $TTS_text =~ s/--A--address2--B--/$TTS_address2/gi; + $TTS_text =~ s/--A--address3--B--/$TTS_address3/gi; + $TTS_text =~ s/--A--city--B--/$TTS_city/gi; + $TTS_text =~ s/--A--state--B--/$TTS_state/gi; + $TTS_text =~ s/--A--province--B--/$TTS_province/gi; + $TTS_text =~ s/--A--postal_code--B--/$TTS_postal_code/gi; + $TTS_text =~ s/--A--country_code--B--/$TTS_country_code/gi; + $TTS_text =~ s/--A--gender--B--/$TTS_gender/gi; + $TTS_text =~ s/--A--date_of_birth--B--/$TTS_date_of_birth/gi; + $TTS_text =~ s/--A--alt_phone--B--/$TTS_alt_phone/gi; + $TTS_text =~ s/--A--email--B--/$TTS_email/gi; + $TTS_text =~ s/--A--security_phrase--B--/$TTS_security_phrase/gi; + $TTS_text =~ s/--A--comments--B--/$TTS_comments/gi; + $TTS_text =~ s/--A--called_count--B--/$TTS_called_count/gi; + $TTS_text =~ s/--A--last_local_call_time--B--/$TTS_last_local_call_time/gi; + $TTS_text =~ s/--A--rank--B--/$TTS_rank/gi; + $TTS_text =~ s/--A--owner--B--/$TTS_owner/gi; + $TTS_text =~ s/[^,\.\<\>\'\/\=\_ 0-9a-zA-Z]//gi; + $TTS_textRAW = $TTS_text; + $TTS_text =~ s/ /\\ /gi; + $TTS_text =~ s/\./\\./gi; + $TTS_text =~ s/\=/\\=/gi; + $TTS_text =~ s/\/\\>/gi; + $TTS_text =~ s/\//\\\//gi; + $TTS_text =~ s/\'/\\'/gi; + $voice = 'Allison-8kHz'; + print STDERR "\nGenerating: $TTS_text - $voice\n"; + `$PATHagi/cepstral_generate.pl --debug --voice=$voice --dialog=$TTS_text >> $CEPLOGfile `; + + use Digest::MD5 qw(md5_hex); + + $enc = md5_hex("$TTS_textRAW-$voice"); # the hash + $enc_ftl = substr($enc, 0, 2); # first letter of hash + $TTS_filename_path = $PATHsounds . "/tts/" . $enc_ftl . "/tts-" . $enc; + print STDERR "\nfilename: $TTS_filename_path\n"; + + $DB_am_message_exten = $TTS_filename_path; + } + $sthA->finish(); + } + ##### END Check if prompt uses TTS, if so, create TTS and set the filename to the generated prompt ##### + + + ### run waitforsilence if enabled + if (length($waitforsilence_options) > 0) + { + $AGI->exec("WaitForSilence","$waitforsilence_options"); + } + + ### play messages + if ($DB_am_message_exten =~ /\|/) + { + @DB_am_message_exten_array = split(/\|/,$DB_am_message_exten); + $w=0; + foreach(@DB_am_message_exten_array) + { + if (length($DB_am_message_exten_array[$w])>0) + { + $AGI->stream_file("$DB_am_message_exten_array[$w]"); + } + $w++; + } + } + else + {$AGI->stream_file("$DB_am_message_exten");} + + + $stmtA = "UPDATE vicidial_log set status='AL' where lead_id='$VD_lead_id' order by call_date desc limit 1;"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $affected_rows = $dbhA->do($stmtA); + if ($AGILOG) {$agi_string = "-- VDAD vicidial_log AL update: |$affected_rows|$uniqueid|"; &agi_output;} + + $stmtA = "UPDATE vicidial_list set status='AL' where lead_id='$VD_lead_id';"; + if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;} + $affected_rows = $dbhA->do($stmtA); + if ($AGILOG) {$agi_string = "-- VDAD vicidial_list AL update: |$affected_rows|$uniqueid|"; &agi_output;} + } + + + $dbhA->disconnect(); + + $AGI->hangup($channel); + + exit; + } @@ -410,39 +550,46 @@ exit; exit; -sub checkresult { +sub checkresult + { my ($res) = @_; my $retval; $tests++; chomp $res; - if ($res =~ /^200/) { + if ($res =~ /^200/) + { $res =~ /result=(-?\d+)/; - if (!length($1)) { + if (!length($1)) + { # print STDERR "FAIL ($res)\n"; $fail++; - } else { + } + else + { # print STDERR "PASS ($1)\n"; $pass++; + } } - } else { + else + { # print STDERR "FAIL (unexpected result '$res')\n"; $fail++; + } } -} sub agi_output -{ -if ($AGILOG >=2) { - ### open the log file for writing ### - open(Lout, ">>$AGILOGfile") - || die "Can't open $AGILOGfile: $!\n"; - print Lout "$now_date|$script|$agi_string\n"; - close(Lout); + if ($AGILOG >=2) + { + ### open the log file for writing ### + open(Lout, ">>$AGILOGfile") + || die "Can't open $AGILOGfile: $!\n"; + print Lout "$now_date|$script|$agi_string\n"; + close(Lout); + } + ### send to STDERR writing ### + if ( ($AGILOG == '1') || ($AGILOG == '3') ) + {print STDERR "$now_date|$script|$agi_string\n";} + $agi_string=''; } - ### send to STDERR writing ### -if ( ($AGILOG == '1') || ($AGILOG == '3') ) - {print STDERR "$now_date|$script|$agi_string\n";} -$agi_string=''; -} diff --git a/agc_2-X/trunk/agi/VD_amd_post.agi b/agc_2-X/trunk/agi/VD_amd_post.agi index 07bfbb67..f8362cbc 100644 --- a/agc_2-X/trunk/agi/VD_amd_post.agi +++ b/agc_2-X/trunk/agi/VD_amd_post.agi @@ -1,5 +1,7 @@ #!/usr/bin/perl # +# THIS SCRIPT WILL BE DEPRICATED AND REMOVED BEFORE THE 2.2.0 RELEASE +# # VD_amd_post.agi version 2.0.4 *DBI-version* # # NOTE: This script is only needed with app_amd enabled systems @@ -21,7 +23,7 @@ # ; this is used for playing a message to an answering machine forwarded from AMD in VICIDIAL # ; replace conf with the message file you want to leave # exten => 8320,1,WaitForSilence(2000,2) ; AMD got machine. leave message after recording -# exten => 8320,2,Playback(conf) +# exten => 8320,2,Playback(ding) # exten => 8320,3,AGI(VD_amd_post.agi,${EXTEN}) # exten => 8320,4,Hangup # diff --git a/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi b/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi index b8a66795..3782fbb4 100644 --- a/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi +++ b/agc_2-X/trunk/agi/agi-VDAD_ALL_outbound.agi @@ -2093,8 +2093,7 @@ sub cpd_end_call if ( ($cpd_amd_action =~ /MESSAGE/) && ($cpd_result !~ /Fax/i) ) { - if (length($am_message_exten)>0) - {$DROPexten = "$am_message_exten";} + $DROPexten = "8320"; } $Euniqueid=$uniqueid; diff --git a/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample b/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample index a5b46356..3807ff8e 100644 --- a/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample +++ b/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample @@ -358,11 +358,8 @@ exten => 8307,2,Playback(vm-goodbye) exten => 8307,3,Hangup ; this is used for playing a message to an answering machine forwarded from AMD in VICIDIAL -; replace conf with the message file you want to leave -exten => 8320,1,WaitForSilence(2000,2) ; AMD got machine. leave message after recording -exten => 8320,2,Playback(conf) -exten => 8320,3,AGI(VD_amd_post.agi,${EXTEN}) -exten => 8320,4,Hangup +exten => 8320,1,AGI(VD_amd.agi,${EXTEN}-----YES) +exten => 8320,2,Hangup ; use for selective CallerID hangup by area code(hard-coded) exten => 8352,1,AGI(agi-VDADselective_CID_hangup.agi,${EXTEN}) diff --git a/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample-1.4 b/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample-1.4 index 8681c4e7..3f6633ad 100644 --- a/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample-1.4 +++ b/agc_2-X/trunk/docs/conf_examples/extensions.conf.sample-1.4 @@ -358,11 +358,8 @@ exten => 8307,2,Playback(vm-goodbye) exten => 8307,3,Hangup ; this is used for playing a message to an answering machine forwarded from AMD in VICIDIAL -; replace conf with the message file you want to leave -exten => 8320,1,WaitForSilence(2000,2) ; AMD got machine. leave message after recording -exten => 8320,2,Playback(conf) -exten => 8320,3,AGI(VD_amd_post.agi,${EXTEN}) -exten => 8320,4,Hangup +exten => 8320,1,AGI(VD_amd.agi,${EXTEN}-----YES) +exten => 8320,2,Hangup ; use for selective CallerID hangup by area code(hard-coded) exten => 8352,1,AGI(agi-VDADselective_CID_hangup.agi,${EXTEN}) 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 3a3a5db7..190c0dbb 100644 --- a/agc_2-X/trunk/extras/MySQL_AST_CREATE_tables.sql +++ b/agc_2-X/trunk/extras/MySQL_AST_CREATE_tables.sql @@ -557,7 +557,7 @@ dial_status_e VARCHAR(6), lead_order VARCHAR(30), park_ext VARCHAR(10), park_file_name VARCHAR(10), -web_form_address VARCHAR(255), +web_form_address TEXT, allow_closers ENUM('Y','N'), hopper_level INT(8) UNSIGNED default '1', auto_dial_level VARCHAR(6) default '0', @@ -573,7 +573,7 @@ campaign_recording ENUM('NEVER','ONDEMAND','ALLCALLS','ALLFORCE') default 'ONDEM campaign_rec_filename VARCHAR(50) default 'FULLDATE_CUSTPHONE', campaign_script VARCHAR(10), get_call_launch ENUM('NONE','SCRIPT','WEBFORM') default 'NONE', -am_message_exten VARCHAR(20), +am_message_exten VARCHAR(100) default 'vm-goodbye', amd_send_to_vmx ENUM('Y','N') default 'N', xferconf_a_dtmf VARCHAR(50), xferconf_a_number VARCHAR(50), @@ -673,7 +673,9 @@ call_requeue_button ENUM('Y','N') default 'N', pause_after_each_call ENUM('Y','N') default 'N', no_hopper_dialing ENUM('Y','N') default 'N', agent_dial_owner_only ENUM('NONE','USER','TERRITORY','USER_GROUP') default 'NONE', -agent_display_dialable_leads ENUM('Y','N') default 'N' +agent_display_dialable_leads ENUM('Y','N') default 'N', +web_form_address_two TEXT, +waitforsilence_options VARCHAR(25) default '' ); CREATE TABLE vicidial_lists ( @@ -751,7 +753,7 @@ group_id VARCHAR(20) PRIMARY KEY NOT NULL, group_name VARCHAR(30), group_color VARCHAR(7), active ENUM('Y','N'), -web_form_address VARCHAR(255), +web_form_address TEXT, voicemail_ext VARCHAR(10), next_agent_call ENUM('random','oldest_call_start','oldest_call_finish','overall_user_level','inbound_group_rank','campaign_rank','fewest_calls','fewest_calls_campaign','longest_wait_time') default 'longest_wait_time', fronter_display ENUM('Y','N') default 'Y', @@ -805,7 +807,8 @@ answer_sec_pct_rt_stat_two SMALLINT(5) UNSIGNED default '30', default_group_alias VARCHAR(30) default '', no_agent_no_queue ENUM('N','Y','NO_PAUSED') default 'N', no_agent_action ENUM('CALLMENU','INGROUP','DID','MESSAGE','EXTENSION','VOICEMAIL') default 'MESSAGE', -no_agent_action_value VARCHAR(255) default 'nbdy-avail-to-take-call|vm-goodbye' +no_agent_action_value VARCHAR(255) default 'nbdy-avail-to-take-call|vm-goodbye', +web_form_address_two TEXT ); CREATE TABLE vicidial_stations ( @@ -1140,7 +1143,9 @@ sounds_web_directory VARCHAR(255) default '', active_voicemail_server VARCHAR(15) default '', auto_dial_limit VARCHAR(5) default '4', user_territories_active ENUM('0','1') default '0', -allow_custom_dialplan ENUM('0','1') default '0' +allow_custom_dialplan ENUM('0','1') default '0', +db_schema_update_date DATETIME, +enable_second_webform ENUM('0','1') default '1' ); CREATE TABLE vicidial_campaigns_list_mix ( @@ -1916,7 +1921,7 @@ CREATE INDEX phone_number on vicidial_closer_log (phone_number); CREATE INDEX date_user on vicidial_closer_log (call_date,user); CREATE INDEX comment_a on live_inbound_log (comment_a); -UPDATE system_settings SET db_schema_version='1172'; +UPDATE system_settings SET db_schema_version='1173',db_schema_update_date=NOW(); GRANT RELOAD ON *.* TO cron@'%'; GRANT RELOAD ON *.* TO cron@localhost; diff --git a/agc_2-X/trunk/extras/upgrade_2.2.0.sql b/agc_2-X/trunk/extras/upgrade_2.2.0.sql index d006363a..066e1c65 100644 --- a/agc_2-X/trunk/extras/upgrade_2.2.0.sql +++ b/agc_2-X/trunk/extras/upgrade_2.2.0.sql @@ -534,3 +534,17 @@ ALTER TABLE twoday_vicidial_agent_log ADD dead_sec SMALLINT(5) UNSIGNED default ALTER TABLE system_settings MODIFY sounds_web_server VARCHAR(50) default '127.0.0.1'; UPDATE system_settings SET db_schema_version='1172'; + +ALTER TABLE vicidial_inbound_groups MODIFY web_form_address TEXT; +ALTER TABLE vicidial_inbound_groups ADD web_form_address_two TEXT; + +ALTER TABLE vicidial_campaigns MODIFY web_form_address TEXT; +ALTER TABLE vicidial_campaigns ADD web_form_address_two TEXT; +ALTER TABLE vicidial_campaigns ADD waitforsilence_options VARCHAR(25) default ''; +ALTER TABLE vicidial_campaigns MODIFY am_message_exten VARCHAR(100) default 'vm-goodbye'; +UPDATE vicidial_campaigns SET am_message_exten='vm-goodbye'; + +ALTER TABLE system_settings ADD db_schema_update_date DATETIME; +ALTER TABLE system_settings ADD enable_second_webform ENUM('0','1') default '0'; + +UPDATE system_settings SET db_schema_version='1173',db_schema_update_date=NOW(); diff --git a/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt b/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt index dc9c4901..bbb7368d 100644 --- a/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt +++ b/agc_2-X/trunk/translations/raw_translation_files/TO_BE_TRANSLATED_2.2.0.txt @@ -298,6 +298,10 @@ MUSIC ON HOLD DELETION COMPLETED|| Starts with Eastern timezones and works West|| Starts with Western timezones and works East|| you must select a user group|| +Enable Second Webform|| +WaitForSilence Options|| +If Wait For Silence is desired on calls that are detected as Answering Machines then this field has those options. There are two settings separated by a comma, the first option is how long to detect silence in milliseconds and the second option is for how many times to detect that before playing the message. Default is EMPTY for disabled. A standard value for this would be wait for 2 seconds of silence twice|| +This field is for entering the prompt to play when the agent gets an answering machine and clicks on the Answering Machine Message button in the transfer conference frame. You must set this to either an audio file in the audio store or a TTS prompt if TTS is enabled on your system|| add-file: user_territories.php @@ -318,6 +322,9 @@ Calls in Queue View Disabled for this campaign|| YOU MUST BE PAUSED TO GRAB CALLS IN QUEUE|| +add-file: vdc_script_display.php + + ############################################################ MANAGER Manual diff --git a/agc_2-X/trunk/www/agc/images/vdc_LB_webform_two.gif b/agc_2-X/trunk/www/agc/images/vdc_LB_webform_two.gif new file mode 100644 index 0000000000000000000000000000000000000000..86aa74db16bcc790f6a1d67015b8ee668d8fc3aa GIT binary patch literal 571 zcmV-B0>u4CNk%w1VUYk30K@$jE?zfc5qDq@<*Xh=@c)MD6YE zU0q$Os;U400RR90A^8LV00000EC2ui0FeL?000I5;3tk`X`X1Ru59bRa4gSsZQpH$ z?|kpKj>B(AY!Lu}A}OIj5C;QMMx&8x7zV0Vc+hGFol@5;5Oo$`p(v|elm%3SXsk8| zJf1*V$#f0}9t0l^cnlu}0UsJ3UP2ij1ypxQBae|(Wea&4gav|&T6sr!9wLh#86*WB z27pm~O+=3!1dJZE9#M-XkCYv#B)ud8kb)luz`JW6NVZ9~sUsa343AZ?em}$+zW}V> zsi0bAj|&+Yh=!GraUZiIwN>Ja4Wo}4;J_sUcXdR4MFMDebZDT5GV?T$BZWs{Fm@W` z2phpj5u-Z;1c4hcFaWrHcOWPc0q_Z<0>>`6nkrRdBC%Ien34De^O2lg1Xd*hXKld8 z5&ZOxEIH&6s}Bb@tvq+mkq2`bG%a{YX~e35ngSS7#vnidd&E%vTq!W(&{#ymhGBpw z+9^_1jFQSowFH3-gaQmur_5chk9P!&4GZ^dwvmVv8y0b4gX71LBTJr4xw7TUm@{kM z%=s~c38@@N=s>!(>C>oFt6t5zwd>cgW6Lg$Au0t65jg1H&AYen-@t=rmzS4HN=js8WUQ>LYHDi1!NE8R*Y-}hfDACc; zK|w)|j*b8T0ORB1A^8LV00000EC2ui0FeL?000I5;3tk`X`X1Ru59bRa4gSsZQt#L z?|kpK4a09pYz+W_A_;Lw5CsBJMx&8x76htRXwYf|ol@5u5Oow^p(v|Wlmk?PXskAS z?w+!e=^P3?10M``3m*j@9~vHBLKz+fRCh@uj*wJk3U?ZV1%ZlMcSm?4iXIsxhXj97 zdrd@+9RrIVu^v&1CXSOGrX;!~0gr(n1iiRx9!RrEv!^2+85NFIt$jbi8N2`<1ly;d zT4jz385xI#l#g*Aup_cn;ED{Qjv3y)CBYtbM0`byjtpsVR3@GVadkjs!sfv;pG4h_uYq0q4fp}gs{w{hYkhdx~q(H90QzEXIq1jQp@ zSj!RvG7PeX?if2;I`0I~DMDY`u+}~b9t>E-g$;-kD_+dFvE#>(BTJr4xw7TN3oual z&;UY*&!9t#9!C>oFt6t5zHRuOSF-UO0p|6) {$server_ip = $call_server_ip;} $stmt = "select count(*) from vicidial_campaigns where campaign_id='$campaign' and campaign_allow_inbound='Y';"; if ($format=='debug') {echo "\n";} @@ -714,14 +717,13 @@ if ($ACTION=="RedirectVD") $rslt=mysql_query($stmt, $link); if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02022',$user,$server_ip,$session_name,$one_mysql_log);} } - if ($auto_dial_level < 1) - { - $stmt = "UPDATE vicidial_log set end_epoch='$StarTtime', length_in_sec='$secondS',status='XFER' where uniqueid='$uniqueid';"; - if ($format=='debug') {echo "\n";} - $rslt=mysql_query($stmt, $link); - if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02023',$user,$server_ip,$session_name,$one_mysql_log);} - } - else + + $stmt = "UPDATE vicidial_log set end_epoch='$StarTtime', length_in_sec='$secondS',status='XFER' where uniqueid='$uniqueid';"; + if ($format=='debug') {echo "\n";} + $rslt=mysql_query($stmt, $link); + if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02023',$user,$server_ip,$session_name,$one_mysql_log);} + + if ($nodeletevdac < 1) { $stmt = "DELETE from vicidial_auto_calls where uniqueid='$uniqueid';"; if ($format=='debug') {echo "\n";} @@ -729,8 +731,8 @@ if ($ACTION=="RedirectVD") if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'02024',$user,$server_ip,$session_name,$one_mysql_log);} } $ACTION="Redirect"; + } } -} if ($ACTION=="RedirectToPark") { diff --git a/agc_2-X/trunk/www/agc/vdc_db_query.php b/agc_2-X/trunk/www/agc/vdc_db_query.php index 5e99f8f9..62cf349a 100644 --- a/agc_2-X/trunk/www/agc/vdc_db_query.php +++ b/agc_2-X/trunk/www/agc/vdc_db_query.php @@ -84,6 +84,7 @@ # - $agent_dialed_type - ('MANUAL_OVERRIDE','MANUAL_DIALNOW','MANUAL_PREVIEW',...) # - $wrapup - ('WRAPUP','') # - $vtiger_callback_id - ('16534'...) +# - $nodeletevdac - ('0','1') # # CHANGELOG: # 50629-1044 - First build of script @@ -210,10 +211,11 @@ # 90808-0221 - Added last_state_change to vicidial_live_agents # 90904-1622 - Added timezone sort options for no hopper dialing # 90908-1037 - Added DEAD call logging +# 90916-1839 - Added nodeletevdac # -$version = '2.2.0-121'; -$build = '90908-1037'; +$version = '2.2.0-122'; +$build = '90916-1839'; $mel=1; # Mysql Error Log enabled = 1 $mysql_log_count=244; $one_mysql_log=0; @@ -387,6 +389,8 @@ if (isset($_GET["dial_method"])) {$dial_method=$_GET["dial_method"];} elseif (isset($_POST["dial_method"])) {$dial_method=$_POST["dial_method"];} if (isset($_GET["no_delete_sessions"])) {$no_delete_sessions=$_GET["no_delete_sessions"];} elseif (isset($_POST["no_delete_sessions"])) {$no_delete_sessions=$_POST["no_delete_sessions"];} +if (isset($_GET["nodeletevdac"])) {$nodeletevdac=$_GET["nodeletevdac"];} + elseif (isset($_POST["nodeletevdac"])) {$nodeletevdac=$_POST["nodeletevdac"];} header ("Content-type: text/html; charset=utf-8"); @@ -2595,11 +2599,14 @@ if ($stage == "end") } - ### delete call record from vicidial_auto_calls - $stmt = "DELETE from vicidial_auto_calls where lead_id='$lead_id' and campaign_id='$VDcampaign_id' and uniqueid='$uniqueid';"; - if ($DB) {echo "$stmt\n";} - $rslt=mysql_query($stmt, $link); - if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00081',$user,$server_ip,$session_name,$one_mysql_log);} + if ($nodeletevdac < 1) + { + ### delete call record from vicidial_auto_calls + $stmt = "DELETE from vicidial_auto_calls where lead_id='$lead_id' and campaign_id='$VDcampaign_id' and uniqueid='$uniqueid';"; + if ($DB) {echo "$stmt\n";} + $rslt=mysql_query($stmt, $link); + if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00081',$user,$server_ip,$session_name,$one_mysql_log);} + } $stmt = "UPDATE vicidial_live_agents set status='PAUSED',uniqueid=0,callerid='',channel='',call_server_ip='',last_call_finish='$NOW_TIME',comments='',last_state_change='$NOW_TIME' where user='$user' and server_ip='$server_ip';"; if ($DB) {echo "$stmt\n";} @@ -2663,11 +2670,14 @@ if ($stage == "end") $affected_rows = mysql_affected_rows($linkB); } - # $stmt = "DELETE from vicidial_auto_calls where lead_id='$lead_id' and campaign_id='$campaign' and uniqueid='$uniqueid';"; - $stmt = "DELETE from vicidial_auto_calls where lead_id='$lead_id' and campaign_id='$VDcampaign_id' and callerid LIKE \"M%\";"; - if ($DB) {echo "$stmt\n";} - $rslt=mysql_query($stmt, $link); - if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00086',$user,$server_ip,$session_name,$one_mysql_log);} + if ($nodeletevdac < 1) + { + # $stmt = "DELETE from vicidial_auto_calls where lead_id='$lead_id' and campaign_id='$campaign' and uniqueid='$uniqueid';"; + $stmt = "DELETE from vicidial_auto_calls where lead_id='$lead_id' and campaign_id='$VDcampaign_id' and callerid LIKE \"M%\";"; + if ($DB) {echo "$stmt\n";} + $rslt=mysql_query($stmt, $link); + if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00086',$user,$server_ip,$session_name,$one_mysql_log);} + } $stmt = "UPDATE vicidial_live_agents set status='PAUSED',uniqueid=0,callerid='',channel='',call_server_ip='',last_call_finish='$NOW_TIME',comments='',last_state_change='$NOW_TIME' where user='$user' and server_ip='$server_ip';"; if ($DB) {echo "$stmt\n";} @@ -3435,7 +3445,7 @@ if ($ACTION == 'VDADcheckINCOMING') $VDCL_front_VDlog =$row[0]; } - $stmt = "select group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias from vicidial_inbound_groups where group_id='$VDADchannel_group';"; + $stmt = "select group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias,web_form_address_two from vicidial_inbound_groups where group_id='$VDADchannel_group';"; if ($DB) {echo "$stmt\n";} $rslt=mysql_query($stmt, $link); if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00119',$user,$server_ip,$session_name,$one_mysql_log);} @@ -3457,6 +3467,7 @@ if ($ACTION == 'VDADcheckINCOMING') $VDCL_ingroup_recording_override = $row[11]; $VDCL_ingroup_rec_filename = $row[12]; $VDCL_default_group_alias = $row[13]; + $VDCL_group_web_two = stripslashes($row[14]); $stmt = "select campaign_script,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_group_alias from vicidial_campaigns where campaign_id='$campaign';"; @@ -3561,8 +3572,8 @@ if ($ACTION == 'VDADcheckINCOMING') } ### if web form is set then send on to vicidial.php for override of WEB_FORM address - if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|\n";} - else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|\n";} + if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|\n";} + else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|\n";} $stmt = "SELECT full_name from vicidial_users where user='$tsr';"; if ($DB) {echo "$stmt\n";} diff --git a/agc_2-X/trunk/www/agc/vicidial.php b/agc_2-X/trunk/www/agc/vicidial.php index 56db650b..1321a3c9 100644 --- a/agc_2-X/trunk/www/agc/vicidial.php +++ b/agc_2-X/trunk/www/agc/vicidial.php @@ -252,10 +252,11 @@ # 90831-1456 - Added active_agent_login_server option for servers # 90908-1038 - Added DEAD call display # 90909-0921 - Fixed park issues +# 90916-1144 - Added Second web form button, Answering Machine Message change # -$version = '2.2.0-229'; -$build = '90909-0921'; +$version = '2.2.0-230'; +$build = '90916-1144'; $mel=1; # Mysql Error Log enabled = 1 $mysql_log_count=61; $one_mysql_log=0; @@ -333,7 +334,7 @@ $random = (rand(1000000, 9999999) + 10000000); ############################################# ##### START SYSTEM_SETTINGS LOOKUP ##### -$stmt = "SELECT use_non_latin,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,webroot_writable,timeclock_end_of_day,vtiger_url,enable_vtiger_integration,outbound_autodial_active FROM system_settings;"; +$stmt = "SELECT use_non_latin,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,webroot_writable,timeclock_end_of_day,vtiger_url,enable_vtiger_integration,outbound_autodial_active,enable_second_webform FROM system_settings;"; $rslt=mysql_query($stmt, $link); if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'01001',$VD_login,$server_ip,$session_name,$one_mysql_log);} if ($DB) {echo "$stmt\n";} @@ -351,6 +352,7 @@ while ($i < $qm_conf_ct) $vtiger_url = $row[6]; $enable_vtiger_integration = $row[7]; $outbound_autodial_active = $row[8]; + $enable_second_webform = $row[9]; $i++; } @@ -1083,7 +1085,7 @@ $VDloginDISPLAY=0; $HKstatusnames = substr("$HKstatusnames", 0, -1); ##### grab the campaign settings - $stmt="SELECT park_ext,park_file_name,web_form_address,allow_closers,auto_dial_level,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,agent_pause_codes_active,no_hopper_leads_logins,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,xfer_groups,disable_alter_custphone,display_queue_count,manual_dial_filter,agent_clipboard_copy,use_campaign_dnc,three_way_call_cid,dial_method,three_way_dial_prefix,web_form_target,vtiger_screen_login,agent_allow_group_alias,default_group_alias,quick_transfer_button,prepopulate_transfer_preset,view_calls_in_queue,view_calls_in_queue_launch,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads FROM vicidial_campaigns where campaign_id = '$VD_campaign';"; + $stmt="SELECT park_ext,park_file_name,web_form_address,allow_closers,auto_dial_level,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,agent_pause_codes_active,no_hopper_leads_logins,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,xfer_groups,disable_alter_custphone,display_queue_count,manual_dial_filter,agent_clipboard_copy,use_campaign_dnc,three_way_call_cid,dial_method,three_way_dial_prefix,web_form_target,vtiger_screen_login,agent_allow_group_alias,default_group_alias,quick_transfer_button,prepopulate_transfer_preset,view_calls_in_queue,view_calls_in_queue_launch,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads,web_form_address_two FROM vicidial_campaigns where campaign_id = '$VD_campaign';"; $rslt=mysql_query($stmt, $link); if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'01013',$VD_login,$server_ip,$session_name,$one_mysql_log);} if ($DB) {echo "$stmt\n";} @@ -1102,7 +1104,7 @@ $VDloginDISPLAY=0; $campaign_rec_filename = $row[11]; $campaign_script = $row[12]; $get_call_launch = $row[13]; - $campaign_am_message_exten = $row[14]; + $campaign_am_message_exten = '8320'; $xferconf_a_dtmf = $row[15]; $xferconf_a_number = $row[16]; $xferconf_b_dtmf = $row[17]; @@ -1142,6 +1144,7 @@ $VDloginDISPLAY=0; $no_hopper_dialing = $row[51]; $agent_dial_owner_only = $row[52]; $agent_display_dialable_leads = $row[53]; + $web_form_address_two = $row[54]; if (preg_match("/Y/",$agent_display_dialable_leads)) {$agent_display_dialable_leads=1;} @@ -1681,10 +1684,23 @@ else $VICIDiaL_web_form_address = "$VICIDiaL_web_URL"; print "\n"; $VICIDiaL_web_form_address_enc = rawurlencode($VICIDiaL_web_form_address); - } $VICIDiaL_web_form_address_enc = rawurlencode($VICIDiaL_web_form_address); + # If a web form address two is not set, use the first one + if (strlen($web_form_address_two)>0) + { + $VICIDiaL_web_form_address_two = "$web_form_address_two"; + print "\n"; + } + else + { + $VICIDiaL_web_form_address_two = "$VICIDiaL_web_form_address"; + print "\n"; + $VICIDiaL_web_form_address_two_enc = rawurlencode($VICIDiaL_web_form_address_two); + } + $VICIDiaL_web_form_address_two_enc = rawurlencode($VICIDiaL_web_form_address_two); + # If closers are allowed on this campaign if ($allow_closers=="Y") { @@ -2322,6 +2338,8 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var VICIDiaL_web_form_address_enc = ''; var VICIDiaL_web_form_address = ''; var VDIC_web_form_address = ''; + var VICIDiaL_web_form_address_two_enc = ''; + var VICIDiaL_web_form_address_two = ''; var CalL_ScripT_id = ''; var CalL_AutO_LauncH = ''; var panel_bgcolor = ''; @@ -2486,6 +2504,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var dial_method = ''; var web_form_target = ''; var TEMP_VDIC_web_form_address = ''; + var TEMP_VDIC_web_form_address_two = ''; var APIPausE_ID = '99999'; var APIDiaL_ID = '99999'; var CheckDEADcall = 0; @@ -2517,6 +2536,8 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var no_empty_session_warnings = ''; var script_width = ''; var script_height = ''; + var enable_second_webform = ''; + var no_delete_VDAC=0; var DiaLControl_auto_HTML = "\"\"Resume\""; var DiaLControl_auto_HTML_ready = "\"\"Resume\""; var DiaLControl_auto_HTML_OFF = "\"\"Resume\""; @@ -3576,8 +3597,12 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} {blindxferdialstring = temp_dial_prefix + "" + temp_phone_code + "" + blindxferdialstring;} } } + no_delete_VDAC=0; if (taskvar == 'XfeRVMAIL') - {var blindxferdialstring = campaign_am_message_exten;} + { + var blindxferdialstring = campaign_am_message_exten; + no_delete_VDAC=1; + } if (blindxferdialstring.length<'2') { xferredirect_query=''; @@ -3586,7 +3611,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} } else { - xferredirect_query = "server_ip=" + server_ip + "&session_name=" + session_name + "&user=" + user + "&pass=" + pass + "&ACTION=RedirectVD&format=text&channel=" + redirectvalue + "&call_server_ip=" + redirectserverip + "&queryCID=" + queryCID + "&exten=" + blindxferdialstring + "&ext_context=" + ext_context + "&ext_priority=1&auto_dial_level=" + auto_dial_level + "&campaign=" + campaign + "&uniqueid=" + document.vicidial_form.uniqueid.value + "&lead_id=" + document.vicidial_form.lead_id.value + "&secondS=" + VD_live_call_secondS + "&session_id=" + session_id; + xferredirect_query = "server_ip=" + server_ip + "&session_name=" + session_name + "&user=" + user + "&pass=" + pass + "&ACTION=RedirectVD&format=text&channel=" + redirectvalue + "&call_server_ip=" + redirectserverip + "&queryCID=" + queryCID + "&exten=" + blindxferdialstring + "&ext_context=" + ext_context + "&ext_priority=1&auto_dial_level=" + auto_dial_level + "&campaign=" + campaign + "&uniqueid=" + document.vicidial_form.uniqueid.value + "&lead_id=" + document.vicidial_form.lead_id.value + "&secondS=" + VD_live_call_secondS + "&session_id=" + session_id + "&nodeletevdac=" + no_delete_VDAC; } } if (taskvar == 'XfeRINTERNAL') @@ -3775,7 +3800,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} document.vicidial_form.callserverip.value = ''; if( document.images ) { document.images['livecall'].src = image_livecall_OFF.src;} // alert(RedirecTxFEr + "|" + auto_dial_level); - dialedcall_send_hangup(taskdispowindow); + dialedcall_send_hangup(taskdispowindow,'','',no_delete_VDAC); } } @@ -3792,7 +3817,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} } // ################################################################################ // Insert or update the vicidial_log entry for a customer call - function DialLog(taskMDstage) + function DialLog(taskMDstage,nodeletevdac) { if (taskMDstage == "start") { @@ -3845,7 +3870,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} "&list_id=" + document.vicidial_form.list_id.value + "&length_in_sec=0&phone_code=" + document.vicidial_form.phone_code.value + "&phone_number=" + lead_dial_number + - "&exten=" + extension + "&channel=" + lastcustchannel + "&start_epoch=" + MDlogEPOCH + "&auto_dial_level=" + auto_dial_level + "&VDstop_rec_after_each_call=" + VDstop_rec_after_each_call + "&conf_silent_prefix=" + conf_silent_prefix + "&protocol=" + protocol + "&extension=" + extension + "&ext_context=" + ext_context + "&conf_exten=" + session_id + "&user_abb=" + user_abb + "&agent_log_id=" + agent_log_id + "&MDnextCID=" + LasTCID + "&inOUT=" + inOUT + "&alt_dial=" + dialed_label + "&DB=0" + "&agentchannel=" + agentchannel + "&conf_dialed=" + conf_dialed + "&leaving_threeway=" + leaving_threeway + "&hangup_all_non_reserved=" + hangup_all_non_reserved + "&blind_transfer=" + blind_transfer + "&dial_method" + dial_method; + "&exten=" + extension + "&channel=" + lastcustchannel + "&start_epoch=" + MDlogEPOCH + "&auto_dial_level=" + auto_dial_level + "&VDstop_rec_after_each_call=" + VDstop_rec_after_each_call + "&conf_silent_prefix=" + conf_silent_prefix + "&protocol=" + protocol + "&extension=" + extension + "&ext_context=" + ext_context + "&conf_exten=" + session_id + "&user_abb=" + user_abb + "&agent_log_id=" + agent_log_id + "&MDnextCID=" + LasTCID + "&inOUT=" + inOUT + "&alt_dial=" + dialed_label + "&DB=0" + "&agentchannel=" + agentchannel + "&conf_dialed=" + conf_dialed + "&leaving_threeway=" + leaving_threeway + "&hangup_all_non_reserved=" + hangup_all_non_reserved + "&blind_transfer=" + blind_transfer + "&dial_method" + dial_method + "&nodeletevdac=" + nodeletevdac; xmlhttp.open('POST', 'vdc_db_query.php'); xmlhttp.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=UTF-8'); // document.getElementById("busycallsdebug").innerHTML = "vdc_db_query.php?" + manDiaLlog_query; @@ -4693,7 +4718,92 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} TEMP_VDIC_web_form_address = VDIC_web_form_address + "" + web_form_vars; } + if (VDIC_web_form_address_two.match(regWFAcustom)) + { + URLDecode(VDIC_web_form_address_two,'YES'); + TEMP_VDIC_web_form_address_two = decoded; + TEMP_VDIC_web_form_address_two = TEMP_VDIC_web_form_address_two.replace(regWFAcustom, ''); + } + else + { + web_form_vars_two = + "lead_id=" + document.vicidial_form.lead_id.value + + "&vendor_id=" + document.vicidial_form.vendor_lead_code.value + + "&list_id=" + document.vicidial_form.list_id.value + + "&gmt_offset_now=" + document.vicidial_form.gmt_offset_now.value + + "&phone_code=" + document.vicidial_form.phone_code.value + + "&phone_number=" + document.vicidial_form.phone_number.value + + "&title=" + document.vicidial_form.title.value + + "&first_name=" + document.vicidial_form.first_name.value + + "&middle_initial=" + document.vicidial_form.middle_initial.value + + "&last_name=" + document.vicidial_form.last_name.value + + "&address1=" + document.vicidial_form.address1.value + + "&address2=" + document.vicidial_form.address2.value + + "&address3=" + document.vicidial_form.address3.value + + "&city=" + document.vicidial_form.city.value + + "&state=" + document.vicidial_form.state.value + + "&province=" + document.vicidial_form.province.value + + "&postal_code=" + document.vicidial_form.postal_code.value + + "&country_code=" + document.vicidial_form.country_code.value + + "&gender=" + document.vicidial_form.gender.value + + "&date_of_birth=" + document.vicidial_form.date_of_birth.value + + "&alt_phone=" + document.vicidial_form.alt_phone.value + + "&email=" + document.vicidial_form.email.value + + "&security_phrase=" + document.vicidial_form.security_phrase.value + + "&comments=" + document.vicidial_form.comments.value + + "&user=" + user + + "&pass=" + pass + + "&campaign=" + campaign + + "&phone_login=" + phone_login + + "&original_phone_login=" + original_phone_login + + "&phone_pass=" + phone_pass + + "&fronter=" + fronter + + "&closer=" + user + + "&group=" + group + + "&channel_group=" + group + + "&SQLdate=" + SQLdate + + "&epoch=" + UnixTime + + "&uniqueid=" + document.vicidial_form.uniqueid.value + + "&customer_zap_channel=" + lastcustchannel + + "&customer_server_ip=" + lastcustserverip + + "&server_ip=" + server_ip + + "&SIPexten=" + extension + + "&session_id=" + session_id + + "&phone=" + document.vicidial_form.phone_number.value + + "&parked_by=" + document.vicidial_form.lead_id.value + + "&dispo=" + LeaDDispO + '' + + "&dialed_number=" + dialed_number + '' + + "&dialed_label=" + dialed_label + '' + + "&source_id=" + source_id + '' + + "&rank=" + document.vicidial_form.rank.value + '' + + "&owner=" + document.vicidial_form.owner.value + '' + + "&camp_script=" + campaign_script + '' + + "&in_script=" + CalL_ScripT_id + '' + + "&script_width=" + script_width + '' + + "&script_height=" + script_height + '' + + "&fullname=" + LOGfullname + '' + + webform_session; + + var regWFspace = new RegExp(" ","ig"); + web_form_vars_two = web_form_vars_two.replace(regWF, ''); + var regWF = new RegExp("\\`|\\~|\\:|\\;|\\#|\\'|\\\"|\\{|\\}|\\(|\\)|\\*|\\^|\\%|\\$|\\!|\\%|\\r|\\t|\\n","ig"); + web_form_vars_two = web_form_vars_two.replace(regWFspace, '+'); + web_form_vars_two = web_form_vars_two.replace(regWF, ''); + + var regWFAvars = new RegExp("\\?","ig"); + if (VDIC_web_form_address_two.match(regWFAvars)) + {web_form_vars_two = '&' + web_form_vars_two} + else + {web_form_vars_two = '?' + web_form_vars_two} + + TEMP_VDIC_web_form_address_two = VDIC_web_form_address_two + "" + web_form_vars_two; + } + document.getElementById("WebFormSpan").innerHTML = "\"Web\n"; + if (enable_second_webform > 0) + { + document.getElementById("WebFormSpanTwo").innerHTML = "\"Web\n"; + } if (LeaDPreVDispO == 'CALLBK') { @@ -4731,6 +4841,10 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} { window.open(TEMP_VDIC_web_form_address, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450'); } + if (get_call_launch == 'WEBFORMTWO') + { + window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450'); + } } else @@ -5018,12 +5132,14 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} { ScriptPanelToFront(); } - if (get_call_launch == 'WEBFORM') { window.open(TEMP_VDIC_web_form_address, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450'); } - + if (get_call_launch == 'WEBFORMTWO') + { + window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450'); + } } } } @@ -5338,6 +5454,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var VDIC_data_VDAC=check_VDIC_array[1].split("|"); VDIC_web_form_address = VICIDiaL_web_form_address + VDIC_web_form_address_two = VICIDiaL_web_form_address_two var VDIC_fronter=''; var VDIC_data_VDIG=check_VDIC_array[2].split("|"); @@ -5383,6 +5500,9 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} else {LIVE_web_vars = default_web_vars;} + if (VDIC_data_VDIG[17].length > 5) + {VDIC_web_form_address_two = VDIC_data_VDIG[17];} + var VDIC_data_VDFR=check_VDIC_array[3].split("|"); if ( (VDIC_data_VDFR[1].length > 1) && (VDCL_fronter_display == 'Y') ) {VDIC_fronter = " Fronter: " + VDIC_data_VDFR[0] + " - " + VDIC_data_VDFR[1];} @@ -5681,9 +5801,95 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} TEMP_VDIC_web_form_address = VDIC_web_form_address + "" + web_form_vars; } + if (VDIC_web_form_address_two.match(regWFAcustom)) + { + URLDecode(VDIC_web_form_address_two,'YES'); + TEMP_VDIC_web_form_address_two = decoded; + TEMP_VDIC_web_form_address_two = TEMP_VDIC_web_form_address_two.replace(regWFAcustom, ''); + } + else + { + web_form_vars_two = + "lead_id=" + document.vicidial_form.lead_id.value + + "&vendor_id=" + document.vicidial_form.vendor_lead_code.value + + "&list_id=" + document.vicidial_form.list_id.value + + "&gmt_offset_now=" + document.vicidial_form.gmt_offset_now.value + + "&phone_code=" + document.vicidial_form.phone_code.value + + "&phone_number=" + document.vicidial_form.phone_number.value + + "&title=" + document.vicidial_form.title.value + + "&first_name=" + document.vicidial_form.first_name.value + + "&middle_initial=" + document.vicidial_form.middle_initial.value + + "&last_name=" + document.vicidial_form.last_name.value + + "&address1=" + document.vicidial_form.address1.value + + "&address2=" + document.vicidial_form.address2.value + + "&address3=" + document.vicidial_form.address3.value + + "&city=" + document.vicidial_form.city.value + + "&state=" + document.vicidial_form.state.value + + "&province=" + document.vicidial_form.province.value + + "&postal_code=" + document.vicidial_form.postal_code.value + + "&country_code=" + document.vicidial_form.country_code.value + + "&gender=" + document.vicidial_form.gender.value + + "&date_of_birth=" + document.vicidial_form.date_of_birth.value + + "&alt_phone=" + document.vicidial_form.alt_phone.value + + "&email=" + document.vicidial_form.email.value + + "&security_phrase=" + document.vicidial_form.security_phrase.value + + "&comments=" + document.vicidial_form.comments.value + + "&user=" + user + + "&pass=" + pass + + "&campaign=" + campaign + + "&phone_login=" + phone_login + + "&original_phone_login=" + original_phone_login + + "&phone_pass=" + phone_pass + + "&fronter=" + fronter + + "&closer=" + user + + "&group=" + group + + "&channel_group=" + group + + "&SQLdate=" + SQLdate + + "&epoch=" + UnixTime + + "&uniqueid=" + document.vicidial_form.uniqueid.value + + "&customer_zap_channel=" + lastcustchannel + + "&customer_server_ip=" + lastcustserverip + + "&server_ip=" + server_ip + + "&SIPexten=" + extension + + "&session_id=" + session_id + + "&phone=" + document.vicidial_form.phone_number.value + + "&parked_by=" + document.vicidial_form.lead_id.value + + "&dispo=" + LeaDDispO + '' + + "&dialed_number=" + dialed_number + '' + + "&dialed_label=" + dialed_label + '' + + "&source_id=" + source_id + '' + + "&rank=" + document.vicidial_form.rank.value + '' + + "&owner=" + document.vicidial_form.owner.value + '' + + "&camp_script=" + campaign_script + '' + + "&in_script=" + CalL_ScripT_id + '' + + "&script_width=" + script_width + '' + + "&script_height=" + script_height + '' + + "&fullname=" + LOGfullname + '' + + webform_session; + + var regWFspace = new RegExp(" ","ig"); + web_form_vars_two = web_form_vars_two.replace(regWF, ''); + var regWF = new RegExp("\\`|\\~|\\:|\\;|\\#|\\'|\\\"|\\{|\\}|\\(|\\)|\\*|\\^|\\%|\\$|\\!|\\%|\\r|\\t|\\n","ig"); + web_form_vars_two = web_form_vars_two.replace(regWFspace, '+'); + web_form_vars_two = web_form_vars_two.replace(regWF, ''); + + var regWFAvars = new RegExp("\\?","ig"); + if (VDIC_web_form_address_two.match(regWFAvars)) + {web_form_vars_two = '&' + web_form_vars_two} + else + {web_form_vars_two = '?' + web_form_vars_two} + + TEMP_VDIC_web_form_address_two = VDIC_web_form_address_two + "" + web_form_vars_two; + } + document.getElementById("WebFormSpan").innerHTML = "\"Web\n"; + if (enable_second_webform > 0) + { + document.getElementById("WebFormSpanTwo").innerHTML = "\"Web\n"; + } + if ( (LIVE_campaign_recording == 'ALLCALLS') || (LIVE_campaign_recording == 'ALLFORCE') ) {all_record = 'YES';} @@ -5701,6 +5907,10 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} { window.open(TEMP_VDIC_web_form_address, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450'); } + if (CalL_AutO_LauncH == 'WEBFORMTWO') + { + window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450'); + } if ( (CopY_tO_ClipboarD != 'NONE') && (useIE > 0) ) { @@ -5838,6 +6048,120 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} } +// ################################################################################ +// refresh the content of the second web form URL + function WebFormTwoRefresH(taskrefresh,submittask) + { + if (VDCL_group_id.length > 1) + {var group = VDCL_group_id;} + else + {var group = campaign;} + if ( (dialed_label.length < 2) || (dialed_label=='NONE') ) {dialed_label='MAIN';} + + if (submittask != 'YES') + { + var genderIndex = document.getElementById("gender_list").selectedIndex; + var genderValue = document.getElementById('gender_list').options[genderIndex].value; + document.vicidial_form.gender.value = genderValue; + } + + var regWFAcustom = new RegExp("^VAR","ig"); + if (VDIC_web_form_address_two.match(regWFAcustom)) + { + URLDecode(VDIC_web_form_address_two,'YES'); + TEMP_VDIC_web_form_address_two = decoded; + TEMP_VDIC_web_form_address_two = TEMP_VDIC_web_form_address_two.replace(regWFAcustom, ''); + } + else + { + web_form_vars_two = + "lead_id=" + document.vicidial_form.lead_id.value + + "&vendor_id=" + document.vicidial_form.vendor_lead_code.value + + "&list_id=" + document.vicidial_form.list_id.value + + "&gmt_offset_now=" + document.vicidial_form.gmt_offset_now.value + + "&phone_code=" + document.vicidial_form.phone_code.value + + "&phone_number=" + document.vicidial_form.phone_number.value + + "&title=" + document.vicidial_form.title.value + + "&first_name=" + document.vicidial_form.first_name.value + + "&middle_initial=" + document.vicidial_form.middle_initial.value + + "&last_name=" + document.vicidial_form.last_name.value + + "&address1=" + document.vicidial_form.address1.value + + "&address2=" + document.vicidial_form.address2.value + + "&address3=" + document.vicidial_form.address3.value + + "&city=" + document.vicidial_form.city.value + + "&state=" + document.vicidial_form.state.value + + "&province=" + document.vicidial_form.province.value + + "&postal_code=" + document.vicidial_form.postal_code.value + + "&country_code=" + document.vicidial_form.country_code.value + + "&gender=" + document.vicidial_form.gender.value + + "&date_of_birth=" + document.vicidial_form.date_of_birth.value + + "&alt_phone=" + document.vicidial_form.alt_phone.value + + "&email=" + document.vicidial_form.email.value + + "&security_phrase=" + document.vicidial_form.security_phrase.value + + "&comments=" + document.vicidial_form.comments.value + + "&user=" + user + + "&pass=" + pass + + "&campaign=" + campaign + + "&phone_login=" + phone_login + + "&original_phone_login=" + original_phone_login + + "&phone_pass=" + phone_pass + + "&fronter=" + fronter + + "&closer=" + user + + "&group=" + group + + "&channel_group=" + group + + "&SQLdate=" + SQLdate + + "&epoch=" + UnixTime + + "&uniqueid=" + document.vicidial_form.uniqueid.value + + "&customer_zap_channel=" + lastcustchannel + + "&customer_server_ip=" + lastcustserverip + + "&server_ip=" + server_ip + + "&SIPexten=" + extension + + "&session_id=" + session_id + + "&phone=" + document.vicidial_form.phone_number.value + + "&parked_by=" + document.vicidial_form.lead_id.value + + "&dispo=" + LeaDDispO + '' + + "&dialed_number=" + dialed_number + '' + + "&dialed_label=" + dialed_label + '' + + "&source_id=" + source_id + '' + + "&rank=" + document.vicidial_form.rank.value + '' + + "&owner=" + document.vicidial_form.owner.value + '' + + "&camp_script=" + campaign_script + '' + + "&in_script=" + CalL_ScripT_id + '' + + "&script_width=" + script_width + '' + + "&script_height=" + script_height + '' + + "&fullname=" + LOGfullname + '' + + webform_session; + + var regWFspace = new RegExp(" ","ig"); + web_form_vars_two = web_form_vars_two.replace(regWF, ''); + var regWF = new RegExp("\\`|\\~|\\:|\\;|\\#|\\'|\\\"|\\{|\\}|\\(|\\)|\\*|\\^|\\%|\\$|\\!|\\%|\\r|\\t|\\n","ig"); + web_form_vars_two = web_form_vars_two.replace(regWFspace, '+'); + web_form_vars_two = web_form_vars_two.replace(regWF, ''); + + var regWFAvars = new RegExp("\\?","ig"); + if (VDIC_web_form_address_two.match(regWFAvars)) + {web_form_vars_two = '&' + web_form_vars_two} + else + {web_form_vars_two = '?' + web_form_vars_two} + + TEMP_VDIC_web_form_address_two = VDIC_web_form_address_two + "" + web_form_vars_two; + } + + + if (enable_second_webform > 0) + { + if (taskrefresh == 'OUT') + { + document.getElementById("WebFormSpanTwo").innerHTML = "\"Web\n"; + } + else + { + document.getElementById("WebFormSpanTwo").innerHTML = "\"Web\n"; + } + } + } + + // ################################################################################ // Send hangup a second time from the dispo screen function DispoHanguPAgaiN() @@ -5889,7 +6213,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} // ################################################################################ // Send Hangup command for customer call connected to the conference now to Manager - function dialedcall_send_hangup(dispowindow,hotkeysused,altdispo) + function dialedcall_send_hangup(dispowindow,hotkeysused,altdispo,nodeletevdac) { if (VDCL_group_id.length > 1) {var group = VDCL_group_id;} @@ -5935,7 +6259,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var queryCID = "HLvdcW" + epoch_sec + user_abb; var hangupvalue = customer_channel; // alert(auto_dial_level + "|" + CalLCID + "|" + customer_server_ip + "|" + hangupvalue + "|" + VD_live_call_secondS); - custhangup_query = "server_ip=" + server_ip + "&session_name=" + session_name + "&ACTION=Hangup&format=text&user=" + user + "&pass=" + pass + "&channel=" + hangupvalue + "&call_server_ip=" + customer_server_ip + "&queryCID=" + queryCID + "&auto_dial_level=" + auto_dial_level + "&CalLCID=" + CalLCID + "&secondS=" + VD_live_call_secondS + "&exten=" + session_id + "&campaign=" + group + "&stage=CALLHANGUP"; + custhangup_query = "server_ip=" + server_ip + "&session_name=" + session_name + "&ACTION=Hangup&format=text&user=" + user + "&pass=" + pass + "&channel=" + hangupvalue + "&call_server_ip=" + customer_server_ip + "&queryCID=" + queryCID + "&auto_dial_level=" + auto_dial_level + "&CalLCID=" + CalLCID + "&secondS=" + VD_live_call_secondS + "&exten=" + session_id + "&campaign=" + group + "&stage=CALLHANGUP&nodeletevdac=" + nodeletevdac; xmlhttp.open('POST', 'manager_send.php'); xmlhttp.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=UTF-8'); xmlhttp.send(custhangup_query); @@ -5970,7 +6294,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} MDnextCID = ''; // UPDATE VICIDIAL_LOG ENTRY FOR THIS CALL PROCESS - DialLog("end"); + DialLog("end",nodeletevdac); conf_dialed=0; if (dispowindow == 'NO') { @@ -6018,6 +6342,10 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} if( document.images ) { document.images['livecall'].src = image_livecall_OFF.src;} document.getElementById("WebFormSpan").innerHTML = "\"Web"; + if (enable_second_webform > 0) + { + document.getElementById("WebFormSpanTwo").innerHTML = "\"Web"; + } document.getElementById("ParkControl").innerHTML = "\"Park"; document.getElementById("HangupControl").innerHTML = "\"Hangup"; document.getElementById("XferControl").innerHTML = "\"Transfer"; @@ -6462,7 +6790,10 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} WebFormRefresH('NO','YES'); document.getElementById("WebFormSpan").innerHTML = "\"Web"; - + if (enable_second_webform > 0) + { + document.getElementById("WebFormSpanTwo").innerHTML = "\"Web"; + } window.open(TEMP_VDIC_web_form_address, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450'); DispoSelect_submit(); @@ -9211,6 +9542,10 @@ RECORD ID:
Start Recording

Web Form
+ 0) + {echo "\"Web
\n";} +?>
Park Call
Transfer - Conference
diff --git a/agc_2-X/trunk/www/vicidial/admin.php b/agc_2-X/trunk/www/vicidial/admin.php index 7d4adb9e..2566067a 100644 --- a/agc_2-X/trunk/www/vicidial/admin.php +++ b/agc_2-X/trunk/www/vicidial/admin.php @@ -1112,6 +1112,13 @@ if (isset($_GET["rebuild_music_on_hold"])) {$rebuild_music_on_hold=$_GET["reb elseif (isset($_POST["rebuild_music_on_hold"])) {$rebuild_music_on_hold=$_POST["rebuild_music_on_hold"];} if (isset($_GET["active_agent_login_server"])) {$active_agent_login_server=$_GET["active_agent_login_server"];} elseif (isset($_POST["active_agent_login_server"])) {$active_agent_login_server=$_POST["active_agent_login_server"];} +if (isset($_GET["enable_second_webform"])) {$enable_second_webform=$_GET["enable_second_webform"];} + elseif (isset($_POST["enable_second_webform"])) {$enable_second_webform=$_POST["enable_second_webform"];} +if (isset($_GET["web_form_address_two"])) {$web_form_address_two=$_GET["web_form_address_two"];} + elseif (isset($_POST["web_form_address_two"])) {$web_form_address_two=$_POST["web_form_address_two"];} +if (isset($_GET["waitforsilence_options"])) {$waitforsilence_options=$_GET["waitforsilence_options"];} + elseif (isset($_POST["waitforsilence_options"])) {$waitforsilence_options=$_POST["waitforsilence_options"];} + if (isset($script_id)) {$script_id= strtoupper($script_id);} if (isset($lead_filter_id)) {$lead_filter_id = strtoupper($lead_filter_id);} @@ -1124,7 +1131,7 @@ if (strlen($dial_status) > 0) ############################################# ##### START SYSTEM_SETTINGS LOOKUP ##### -$stmt = "SELECT use_non_latin,enable_queuemetrics_logging,enable_vtiger_integration,qc_features_active,outbound_autodial_active,sounds_central_control_active FROM system_settings;"; +$stmt = "SELECT use_non_latin,enable_queuemetrics_logging,enable_vtiger_integration,qc_features_active,outbound_autodial_active,sounds_central_control_active,enable_second_webform FROM system_settings;"; $rslt=mysql_query($stmt, $link); if ($DB) {echo "$stmt\n";} $qm_conf_ct = mysql_num_rows($rslt); @@ -1138,6 +1145,7 @@ while ($i < $qm_conf_ct) $SSqc_features_active = $row[3]; $SSoutbound_autodial_active = $row[4]; $SSsounds_central_control_active = $row[5]; + $SSenable_second_webform = $row[6]; $i++; } ##### END SETTINGS LOOKUP ##### @@ -1163,7 +1171,6 @@ if ($non_latin < 1) $AGI_call_logging_enabled = ereg_replace("[^0-9]","",$AGI_call_logging_enabled); $allcalls_delay = ereg_replace("[^0-9]","",$allcalls_delay); $alter_agent_interface_options = ereg_replace("[^0-9]","",$alter_agent_interface_options); - $am_message_exten = ereg_replace("[^0-9]","",$am_message_exten); $answer_transfer_agent = ereg_replace("[^0-9]","",$answer_transfer_agent); $ast_admin_access = ereg_replace("[^0-9]","",$ast_admin_access); $ast_delete_phones = ereg_replace("[^0-9]","",$ast_delete_phones); @@ -1309,6 +1316,7 @@ if ($non_latin < 1) $allow_alerts = ereg_replace("[^0-9]","",$allow_alerts); $vicidial_balance_rank = ereg_replace("[^0-9]","",$vicidial_balance_rank); $rank = ereg_replace("[^0-9]","",$rank); + $enable_second_webform = ereg_replace("[^0-9]","",$rank); $drop_call_seconds = ereg_replace("[^-0-9]","",$drop_call_seconds); @@ -1575,8 +1583,9 @@ if ($non_latin < 1) $welcome_message_filename = ereg_replace("[^-\/\|\._0-9a-zA-Z]","",$welcome_message_filename); $onhold_prompt_filename = ereg_replace("[^-\/\|\._0-9a-zA-Z]","",$onhold_prompt_filename); $hold_time_option_callback_filename = ereg_replace("[^-\/\|\._0-9a-zA-Z]","",$hold_time_option_callback_filename); - $agent_alert_exten = ereg_replace("[^-\/\._0-9a-zA-Z]","",$agent_alert_exten); + $agent_alert_exten = ereg_replace("[^-\|\/\._0-9a-zA-Z]","",$agent_alert_exten); $filename = ereg_replace("[^-\/\._0-9a-zA-Z]","",$filename); + $am_message_exten = ereg_replace("[^-\|\/\._0-9a-zA-Z]","",$am_message_exten); ### ALPHA-NUMERIC and underscore and dash and comma $logins_list = ereg_replace("[^-\,\_0-9a-zA-Z]","",$logins_list); @@ -1659,6 +1668,9 @@ if ($non_latin < 1) $vtiger_login = ereg_replace("[^-\.\:\/\@\_0-9a-zA-Z]","",$vtiger_login); $vtiger_pass = ereg_replace("[^-\.\:\/\@\_0-9a-zA-Z]","",$vtiger_pass); + ### NUMERIC and comma and pipe + $waitforsilence_options = ereg_replace("[^\|\,0-9]","",$waitforsilence_options); + ### value cleaning $no_agent_action_value = ereg_replace("[^-\/\|\_\#\*\,\.\_0-9a-zA-Z]","",$no_agent_action_value); @@ -1697,6 +1709,7 @@ if ($non_latin < 1) # $admin_home_url # $qc_web_form_address # $vtiger_url + # $web_form_address_two ### VARIABLES not filtered at all ### # $script_text @@ -1941,11 +1954,12 @@ else # 90830-2217 - Added Music On Hold section # 90904-1536 - Added moh chooser option, timezone list ordering # 90908-1207 - Added cross-listing linking for DIDs, CallMenus and In-groups +# 90916-1105 - Added second web form to ingroups and campaigns and added audio choose for answering machine message and waitforsilence_options # # make sure you have added a user to the vicidial_users MySQL table with at least user_level 8 to access this page the first time -$admin_version = '2.2.0-215'; -$build = '90908-1207'; +$admin_version = '2.2.0-216'; +$build = '90916-1105'; $STARTtime = date("U"); $SQLdate = date("Y-m-d H:i:s"); @@ -3427,7 +3441,12 @@ if ($SSoutbound_autodial_active > 0)

- Answering Machine Message - This field is for entering in an extension to blind transfer calls to when the agent gets an answering machine and clicks on the Answering Machine Message button in the transfer conference frame. You must set this exten up in the dial plan - extensions.conf - and make sure it plays an audio file then hangs up. + Answering Machine Message - This field is for entering the prompt to play when the agent gets an answering machine and clicks on the Answering Machine Message button in the transfer conference frame. You must set this to either an audio file in the audio store or a TTS prompt if TTS is enabled on your system. + +
+
+
+ WaitForSilence Options - If Wait For Silence is desired on calls that are detected as Answering Machines then this field has those options. There are two settings separated by a comma, the first option is how long to detect silence in milliseconds and the second option is for how many times to detect that before playing the message. Default is EMPTY for disabled. A standard value for this would be wait for 2 seconds of silence twice: 2000,2
@@ -5654,6 +5673,11 @@ FR_SPAC 00 00 00 00 00 - France space separated phone number

User Territories Active - This setting allows you to enable the User Territories setttings from the user modification screen. This feature was added to allow for more integration with a customized Vtiger installation but can have applications in a pure ViciDial system as well. Default is 0 for disabled. +
+
+
+Enable Second Webform - This setting allows you to have a second web form for campaigns and in-groups in the agent interface. Default is 0 for disabled. +

@@ -6230,7 +6254,7 @@ if ($ADD==11) echo "Active: $NWB#vicidial_campaigns-active$NWE\n"; echo "Park Extension: $NWB#vicidial_campaigns-park_ext$NWE\n"; echo "Park Filename: $NWB#vicidial_campaigns-park_file_name$NWE\n"; - echo "Web Form: $NWB#vicidial_campaigns-web_form_address$NWE\n"; + echo "Web Form: $NWB#vicidial_campaigns-web_form_address$NWE\n"; if ($SSoutbound_autodial_active > 0) { echo "Allow Closers: $NWB#vicidial_campaigns-allow_closers$NWE\n"; @@ -6634,7 +6658,7 @@ if ($ADD==1111) echo "Group Name: $NWB#vicidial_inbound_groups-group_name$NWE\n"; echo "Group Color: $NWB#vicidial_inbound_groups-group_color$NWE\n"; echo "Active: $NWB#vicidial_inbound_groups-active$NWE\n"; - echo "Web Form: $NWB#vicidial_inbound_groups-web_form_address$NWE\n"; + echo "Web Form: $NWB#vicidial_inbound_groups-web_form_address$NWE\n"; echo "Voicemail: $NWB#vicidial_inbound_groups-voicemail_ext$NWE\n"; echo "Next Agent Call: $NWB#vicidial_inbound_groups-next_agent_call$NWE\n"; echo "Fronter Display: $NWB#vicidial_inbound_groups-fronter_display$NWE\n"; @@ -8283,7 +8307,7 @@ if ($ADD==20) { echo "
CAMPAIGN COPIED: $campaign_id copied from $source_campaign_id\n"; - $stmt="INSERT INTO vicidial_campaigns (campaign_name,campaign_id,active,dial_status_a,dial_status_b,dial_status_c,dial_status_d,dial_status_e,lead_order,park_ext,park_file_name,web_form_address,allow_closers,hopper_level,auto_dial_level,next_agent_call,local_call_time,voicemail_ext,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,amd_send_to_vmx,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,lead_filter_id,drop_call_seconds,drop_action,safe_harbor_exten,display_dialable_count,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,concurrent_transfers,auto_alt_dial,auto_alt_dial_statuses,agent_pause_codes_active,campaign_description,campaign_changedate,campaign_stats_refresh,campaign_logindate,dial_statuses,disable_alter_custdata,no_hopper_leads_logins,list_order_mix,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,queue_priority,drop_inbound_group,qc_enabled,qc_statuses,qc_lists,qc_web_form_address,qc_script,survey_first_audio_file,survey_dtmf_digits,survey_ni_digit,survey_opt_in_audio_file,survey_ni_audio_file,survey_method,survey_no_response_action,survey_ni_status,survey_response_digit_map,survey_xfer_exten,survey_camp_record_dir,disable_alter_custphone,display_queue_count,qc_get_record_launch,qc_show_recording,qc_shift_id,manual_dial_filter,agent_clipboard_copy,agent_extended_alt_dial,use_campaign_dnc,three_way_call_cid,three_way_dial_prefix,web_form_target,vtiger_search_category,vtiger_create_call_record,vtiger_create_lead_record,vtiger_screen_login,cpd_amd_action,agent_allow_group_alias,default_group_alias,vtiger_search_dead,vtiger_status_call,survey_third_digit,survey_fourth_digit,survey_third_audio_file,survey_fourth_audio_file,survey_third_status,survey_fourth_status,survey_third_exten,survey_fourth_exten,drop_lockout_time,quick_transfer_button,prepopulate_transfer_preset,drop_rate_group,view_calls_in_queue,view_calls_in_queue_launch,grab_calls_in_queue,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads) SELECT \"$campaign_name\",\"$campaign_id\",\"N\",dial_status_a,dial_status_b,dial_status_c,dial_status_d,dial_status_e,lead_order,park_ext,park_file_name,web_form_address,allow_closers,hopper_level,auto_dial_level,next_agent_call,local_call_time,voicemail_ext,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,amd_send_to_vmx,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,lead_filter_id,drop_call_seconds,drop_action,safe_harbor_exten,display_dialable_count,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,concurrent_transfers,auto_alt_dial,auto_alt_dial_statuses,agent_pause_codes_active,campaign_description,campaign_changedate,campaign_stats_refresh,campaign_logindate,dial_statuses,disable_alter_custdata,no_hopper_leads_logins,\"DISABLED\",campaign_allow_inbound,manual_dial_list_id,default_xfer_group,queue_priority,drop_inbound_group,qc_enabled,qc_statuses,qc_lists,qc_web_form_address,qc_script,survey_first_audio_file,survey_dtmf_digits,survey_ni_digit,survey_opt_in_audio_file,survey_ni_audio_file,survey_method,survey_no_response_action,survey_ni_status,survey_response_digit_map,survey_xfer_exten,survey_camp_record_dir,disable_alter_custphone,display_queue_count,qc_get_record_launch,qc_show_recording,qc_shift_id,manual_dial_filter,agent_clipboard_copy,agent_extended_alt_dial,use_campaign_dnc,three_way_call_cid,three_way_dial_prefix,web_form_target,vtiger_search_category,vtiger_create_call_record,vtiger_create_lead_record,vtiger_screen_login,cpd_amd_action,agent_allow_group_alias,default_group_alias,vtiger_search_dead,vtiger_status_call,survey_third_digit,survey_fourth_digit,survey_third_audio_file,survey_fourth_audio_file,survey_third_status,survey_fourth_status,survey_third_exten,survey_fourth_exten,drop_lockout_time,quick_transfer_button,prepopulate_transfer_preset,drop_rate_group,view_calls_in_queue,view_calls_in_queue_launch,grab_calls_in_queue,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads from vicidial_campaigns where campaign_id='$source_campaign_id';"; + $stmt="INSERT INTO vicidial_campaigns (campaign_name,campaign_id,active,dial_status_a,dial_status_b,dial_status_c,dial_status_d,dial_status_e,lead_order,park_ext,park_file_name,web_form_address,allow_closers,hopper_level,auto_dial_level,next_agent_call,local_call_time,voicemail_ext,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,amd_send_to_vmx,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,lead_filter_id,drop_call_seconds,drop_action,safe_harbor_exten,display_dialable_count,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,concurrent_transfers,auto_alt_dial,auto_alt_dial_statuses,agent_pause_codes_active,campaign_description,campaign_changedate,campaign_stats_refresh,campaign_logindate,dial_statuses,disable_alter_custdata,no_hopper_leads_logins,list_order_mix,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,queue_priority,drop_inbound_group,qc_enabled,qc_statuses,qc_lists,qc_web_form_address,qc_script,survey_first_audio_file,survey_dtmf_digits,survey_ni_digit,survey_opt_in_audio_file,survey_ni_audio_file,survey_method,survey_no_response_action,survey_ni_status,survey_response_digit_map,survey_xfer_exten,survey_camp_record_dir,disable_alter_custphone,display_queue_count,qc_get_record_launch,qc_show_recording,qc_shift_id,manual_dial_filter,agent_clipboard_copy,agent_extended_alt_dial,use_campaign_dnc,three_way_call_cid,three_way_dial_prefix,web_form_target,vtiger_search_category,vtiger_create_call_record,vtiger_create_lead_record,vtiger_screen_login,cpd_amd_action,agent_allow_group_alias,default_group_alias,vtiger_search_dead,vtiger_status_call,survey_third_digit,survey_fourth_digit,survey_third_audio_file,survey_fourth_audio_file,survey_third_status,survey_fourth_status,survey_third_exten,survey_fourth_exten,drop_lockout_time,quick_transfer_button,prepopulate_transfer_preset,drop_rate_group,view_calls_in_queue,view_calls_in_queue_launch,grab_calls_in_queue,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads,web_form_address_two,waitforsilence_options) SELECT \"$campaign_name\",\"$campaign_id\",\"N\",dial_status_a,dial_status_b,dial_status_c,dial_status_d,dial_status_e,lead_order,park_ext,park_file_name,web_form_address,allow_closers,hopper_level,auto_dial_level,next_agent_call,local_call_time,voicemail_ext,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,amd_send_to_vmx,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,lead_filter_id,drop_call_seconds,drop_action,safe_harbor_exten,display_dialable_count,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,concurrent_transfers,auto_alt_dial,auto_alt_dial_statuses,agent_pause_codes_active,campaign_description,campaign_changedate,campaign_stats_refresh,campaign_logindate,dial_statuses,disable_alter_custdata,no_hopper_leads_logins,\"DISABLED\",campaign_allow_inbound,manual_dial_list_id,default_xfer_group,queue_priority,drop_inbound_group,qc_enabled,qc_statuses,qc_lists,qc_web_form_address,qc_script,survey_first_audio_file,survey_dtmf_digits,survey_ni_digit,survey_opt_in_audio_file,survey_ni_audio_file,survey_method,survey_no_response_action,survey_ni_status,survey_response_digit_map,survey_xfer_exten,survey_camp_record_dir,disable_alter_custphone,display_queue_count,qc_get_record_launch,qc_show_recording,qc_shift_id,manual_dial_filter,agent_clipboard_copy,agent_extended_alt_dial,use_campaign_dnc,three_way_call_cid,three_way_dial_prefix,web_form_target,vtiger_search_category,vtiger_create_call_record,vtiger_create_lead_record,vtiger_screen_login,cpd_amd_action,agent_allow_group_alias,default_group_alias,vtiger_search_dead,vtiger_status_call,survey_third_digit,survey_fourth_digit,survey_third_audio_file,survey_fourth_audio_file,survey_third_status,survey_fourth_status,survey_third_exten,survey_fourth_exten,drop_lockout_time,quick_transfer_button,prepopulate_transfer_preset,drop_rate_group,view_calls_in_queue,view_calls_in_queue_launch,grab_calls_in_queue,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads,web_form_address_two,waitforsilence_options from vicidial_campaigns where campaign_id='$source_campaign_id';"; $rslt=mysql_query($stmt, $link); $stmtA="INSERT INTO vicidial_campaign_stats (campaign_id) values('$campaign_id');"; @@ -8742,7 +8766,7 @@ if ($ADD==2011) } else { - $stmt="INSERT INTO vicidial_inbound_groups (group_id,group_name,group_color,active,web_form_address,voicemail_ext,next_agent_call,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,drop_call_seconds,drop_action,drop_exten,call_time_id,after_hours_action,after_hours_message_filename,after_hours_exten,after_hours_voicemail,welcome_message_filename,moh_context,onhold_prompt_filename,prompt_interval,agent_alert_exten,agent_alert_delay,default_xfer_group,queue_priority,drop_inbound_group,ingroup_recording_override,ingroup_rec_filename,afterhours_xfer_group,qc_enabled,qc_statuses,qc_shift_id,qc_get_record_launch,qc_show_recording,qc_web_form_address,qc_script,play_place_in_line,play_estimate_hold_time,hold_time_option,hold_time_option_seconds,hold_time_option_exten,hold_time_option_voicemail,hold_time_option_xfer_group,hold_time_option_callback_filename,hold_time_option_callback_list_id,hold_recall_xfer_group,no_delay_call_route,play_welcome_message,answer_sec_pct_rt_stat_one,answer_sec_pct_rt_stat_two,default_group_alias,no_agent_no_queue,no_agent_action,no_agent_action_value) SELECT \"$group_id\",\"$group_name\",group_color,\"N\",web_form_address,voicemail_ext,next_agent_call,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,drop_call_seconds,drop_action,drop_exten,call_time_id,after_hours_action,after_hours_message_filename,after_hours_exten,after_hours_voicemail,welcome_message_filename,moh_context,onhold_prompt_filename,prompt_interval,agent_alert_exten,agent_alert_delay,default_xfer_group,queue_priority,drop_inbound_group,ingroup_recording_override,ingroup_rec_filename,afterhours_xfer_group,qc_enabled,qc_statuses,qc_shift_id,qc_get_record_launch,qc_show_recording,qc_web_form_address,qc_script,play_place_in_line,play_estimate_hold_time,hold_time_option,hold_time_option_seconds,hold_time_option_exten,hold_time_option_voicemail,hold_time_option_xfer_group,hold_time_option_callback_filename,hold_time_option_callback_list_id,hold_recall_xfer_group,no_delay_call_route,play_welcome_message,answer_sec_pct_rt_stat_one,answer_sec_pct_rt_stat_two,default_group_alias,no_agent_no_queue,no_agent_action,no_agent_action_value from vicidial_inbound_groups where group_id=\"$source_group_id\";"; + $stmt="INSERT INTO vicidial_inbound_groups (group_id,group_name,group_color,active,web_form_address,voicemail_ext,next_agent_call,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,drop_call_seconds,drop_action,drop_exten,call_time_id,after_hours_action,after_hours_message_filename,after_hours_exten,after_hours_voicemail,welcome_message_filename,moh_context,onhold_prompt_filename,prompt_interval,agent_alert_exten,agent_alert_delay,default_xfer_group,queue_priority,drop_inbound_group,ingroup_recording_override,ingroup_rec_filename,afterhours_xfer_group,qc_enabled,qc_statuses,qc_shift_id,qc_get_record_launch,qc_show_recording,qc_web_form_address,qc_script,play_place_in_line,play_estimate_hold_time,hold_time_option,hold_time_option_seconds,hold_time_option_exten,hold_time_option_voicemail,hold_time_option_xfer_group,hold_time_option_callback_filename,hold_time_option_callback_list_id,hold_recall_xfer_group,no_delay_call_route,play_welcome_message,answer_sec_pct_rt_stat_one,answer_sec_pct_rt_stat_two,default_group_alias,no_agent_no_queue,no_agent_action,no_agent_action_value,web_form_address_two) SELECT \"$group_id\",\"$group_name\",group_color,\"N\",web_form_address,voicemail_ext,next_agent_call,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,drop_call_seconds,drop_action,drop_exten,call_time_id,after_hours_action,after_hours_message_filename,after_hours_exten,after_hours_voicemail,welcome_message_filename,moh_context,onhold_prompt_filename,prompt_interval,agent_alert_exten,agent_alert_delay,default_xfer_group,queue_priority,drop_inbound_group,ingroup_recording_override,ingroup_rec_filename,afterhours_xfer_group,qc_enabled,qc_statuses,qc_shift_id,qc_get_record_launch,qc_show_recording,qc_web_form_address,qc_script,play_place_in_line,play_estimate_hold_time,hold_time_option,hold_time_option_seconds,hold_time_option_exten,hold_time_option_voicemail,hold_time_option_xfer_group,hold_time_option_callback_filename,hold_time_option_callback_list_id,hold_recall_xfer_group,no_delay_call_route,play_welcome_message,answer_sec_pct_rt_stat_one,answer_sec_pct_rt_stat_two,default_group_alias,no_agent_no_queue,no_agent_action,no_agent_action_value,web_form_address_two from vicidial_inbound_groups where group_id=\"$source_group_id\";"; $rslt=mysql_query($stmt, $link); echo "
GROUP ADDED: $group_id\n"; @@ -10695,7 +10719,7 @@ if ($ADD==41) $adaptive_maximum_level = '1.0'; $agent_extended_alt_dial = 'N'; $alt_number_dialing = 'N'; - $am_message_exten = '8300'; + $am_message_exten = '8320'; $amd_send_to_vmx = 'N'; $auto_alt_dial = 'N'; $auto_dial_level = '1.0'; @@ -10813,7 +10837,7 @@ if ($ADD==41) if ( (!ereg("DISABLED",$list_order_mix)) and ($hopper_level < 100) ) {$hopper_level='100';} - $stmtA="UPDATE vicidial_campaigns set campaign_name='$campaign_name',active='$active',dial_status_a='$dial_status_a',dial_status_b='$dial_status_b',dial_status_c='$dial_status_c',dial_status_d='$dial_status_d',dial_status_e='$dial_status_e',lead_order='$lead_order',allow_closers='$allow_closers',hopper_level='$hopper_level', $adlSQL next_agent_call='$next_agent_call', local_call_time='$local_call_time', voicemail_ext='$voicemail_ext', dial_timeout='$dial_timeout', dial_prefix='$dial_prefix', campaign_cid='$campaign_cid', campaign_vdad_exten='$campaign_vdad_exten', web_form_address='" . mysql_real_escape_string($web_form_address) . "', park_ext='$park_ext', park_file_name='$park_file_name', campaign_rec_exten='$campaign_rec_exten', campaign_recording='$campaign_recording', campaign_rec_filename='$campaign_rec_filename', campaign_script='$script_id', get_call_launch='$get_call_launch', am_message_exten='$am_message_exten', amd_send_to_vmx='$amd_send_to_vmx', xferconf_a_dtmf='$xferconf_a_dtmf',xferconf_a_number='$xferconf_a_number',xferconf_b_dtmf='$xferconf_b_dtmf',xferconf_b_number='$xferconf_b_number',lead_filter_id='$lead_filter_id',alt_number_dialing='$alt_number_dialing',scheduled_callbacks='$scheduled_callbacks',drop_action='$drop_action',drop_call_seconds='$drop_call_seconds',safe_harbor_exten='$safe_harbor_exten',wrapup_seconds='$wrapup_seconds',wrapup_message='$wrapup_message',closer_campaigns='$groups_value',use_internal_dnc='$use_internal_dnc',allcalls_delay='$allcalls_delay',omit_phone_code='$omit_phone_code',dial_method='$dial_method',available_only_ratio_tally='$available_only_ratio_tally',adaptive_dropped_percentage='$adaptive_dropped_percentage',adaptive_maximum_level='$adaptive_maximum_level',adaptive_latest_server_time='$adaptive_latest_server_time',adaptive_intensity='$adaptive_intensity',adaptive_dl_diff_target='$adaptive_dl_diff_target',concurrent_transfers='$concurrent_transfers',auto_alt_dial='$auto_alt_dial',agent_pause_codes_active='$agent_pause_codes_active',campaign_description='$campaign_description',campaign_changedate='$SQLdate',campaign_stats_refresh='$campaign_stats_refresh',disable_alter_custdata='$disable_alter_custdata',no_hopper_leads_logins='$no_hopper_leads_logins',list_order_mix='$list_order_mix',campaign_allow_inbound='$campaign_allow_inbound',manual_dial_list_id='$manual_dial_list_id',default_xfer_group='$default_xfer_group',xfer_groups='$XFERgroups_value',queue_priority='$queue_priority',drop_inbound_group='$drop_inbound_group',disable_alter_custphone='$disable_alter_custphone',display_queue_count='$display_queue_count',manual_dial_filter='$manual_dial_filter',agent_clipboard_copy='$agent_clipboard_copy',agent_extended_alt_dial='$agent_extended_alt_dial',use_campaign_dnc='$use_campaign_dnc',three_way_call_cid='$three_way_call_cid',three_way_dial_prefix='$three_way_dial_prefix',web_form_target='$web_form_target',vtiger_search_category='$vtiger_search_category',vtiger_create_call_record='$vtiger_create_call_record',vtiger_create_lead_record='$vtiger_create_lead_record',vtiger_screen_login='$vtiger_screen_login',cpd_amd_action='$cpd_amd_action',agent_allow_group_alias='$agent_allow_group_alias',default_group_alias='$default_group_alias',vtiger_search_dead='$vtiger_search_dead',vtiger_status_call='$vtiger_status_call',drop_lockout_time='$drop_lockout_time',quick_transfer_button='$quick_transfer_button',prepopulate_transfer_preset='$prepopulate_transfer_preset',drop_rate_group='$drop_rate_group',view_calls_in_queue='$view_calls_in_queue',view_calls_in_queue_launch='$view_calls_in_queue_launch',grab_calls_in_queue='$grab_calls_in_queue',call_requeue_button='$call_requeue_button',pause_after_each_call='$pause_after_each_call',no_hopper_dialing='$no_hopper_dialing',agent_dial_owner_only='$agent_dial_owner_only',agent_display_dialable_leads='$agent_display_dialable_leads' where campaign_id='$campaign_id';"; + $stmtA="UPDATE vicidial_campaigns set campaign_name='$campaign_name',active='$active',dial_status_a='$dial_status_a',dial_status_b='$dial_status_b',dial_status_c='$dial_status_c',dial_status_d='$dial_status_d',dial_status_e='$dial_status_e',lead_order='$lead_order',allow_closers='$allow_closers',hopper_level='$hopper_level', $adlSQL next_agent_call='$next_agent_call', local_call_time='$local_call_time', voicemail_ext='$voicemail_ext', dial_timeout='$dial_timeout', dial_prefix='$dial_prefix', campaign_cid='$campaign_cid', campaign_vdad_exten='$campaign_vdad_exten', web_form_address='" . mysql_real_escape_string($web_form_address) . "', park_ext='$park_ext', park_file_name='$park_file_name', campaign_rec_exten='$campaign_rec_exten', campaign_recording='$campaign_recording', campaign_rec_filename='$campaign_rec_filename', campaign_script='$script_id', get_call_launch='$get_call_launch', am_message_exten='$am_message_exten', amd_send_to_vmx='$amd_send_to_vmx', xferconf_a_dtmf='$xferconf_a_dtmf',xferconf_a_number='$xferconf_a_number',xferconf_b_dtmf='$xferconf_b_dtmf',xferconf_b_number='$xferconf_b_number',lead_filter_id='$lead_filter_id',alt_number_dialing='$alt_number_dialing',scheduled_callbacks='$scheduled_callbacks',drop_action='$drop_action',drop_call_seconds='$drop_call_seconds',safe_harbor_exten='$safe_harbor_exten',wrapup_seconds='$wrapup_seconds',wrapup_message='$wrapup_message',closer_campaigns='$groups_value',use_internal_dnc='$use_internal_dnc',allcalls_delay='$allcalls_delay',omit_phone_code='$omit_phone_code',dial_method='$dial_method',available_only_ratio_tally='$available_only_ratio_tally',adaptive_dropped_percentage='$adaptive_dropped_percentage',adaptive_maximum_level='$adaptive_maximum_level',adaptive_latest_server_time='$adaptive_latest_server_time',adaptive_intensity='$adaptive_intensity',adaptive_dl_diff_target='$adaptive_dl_diff_target',concurrent_transfers='$concurrent_transfers',auto_alt_dial='$auto_alt_dial',agent_pause_codes_active='$agent_pause_codes_active',campaign_description='$campaign_description',campaign_changedate='$SQLdate',campaign_stats_refresh='$campaign_stats_refresh',disable_alter_custdata='$disable_alter_custdata',no_hopper_leads_logins='$no_hopper_leads_logins',list_order_mix='$list_order_mix',campaign_allow_inbound='$campaign_allow_inbound',manual_dial_list_id='$manual_dial_list_id',default_xfer_group='$default_xfer_group',xfer_groups='$XFERgroups_value',queue_priority='$queue_priority',drop_inbound_group='$drop_inbound_group',disable_alter_custphone='$disable_alter_custphone',display_queue_count='$display_queue_count',manual_dial_filter='$manual_dial_filter',agent_clipboard_copy='$agent_clipboard_copy',agent_extended_alt_dial='$agent_extended_alt_dial',use_campaign_dnc='$use_campaign_dnc',three_way_call_cid='$three_way_call_cid',three_way_dial_prefix='$three_way_dial_prefix',web_form_target='$web_form_target',vtiger_search_category='$vtiger_search_category',vtiger_create_call_record='$vtiger_create_call_record',vtiger_create_lead_record='$vtiger_create_lead_record',vtiger_screen_login='$vtiger_screen_login',cpd_amd_action='$cpd_amd_action',agent_allow_group_alias='$agent_allow_group_alias',default_group_alias='$default_group_alias',vtiger_search_dead='$vtiger_search_dead',vtiger_status_call='$vtiger_status_call',drop_lockout_time='$drop_lockout_time',quick_transfer_button='$quick_transfer_button',prepopulate_transfer_preset='$prepopulate_transfer_preset',drop_rate_group='$drop_rate_group',view_calls_in_queue='$view_calls_in_queue',view_calls_in_queue_launch='$view_calls_in_queue_launch',grab_calls_in_queue='$grab_calls_in_queue',call_requeue_button='$call_requeue_button',pause_after_each_call='$pause_after_each_call',no_hopper_dialing='$no_hopper_dialing',agent_dial_owner_only='$agent_dial_owner_only',agent_display_dialable_leads='$agent_display_dialable_leads',web_form_address_two='" . mysql_real_escape_string($web_form_address_two) . "',waitforsilence_options='$waitforsilence_options' where campaign_id='$campaign_id';"; $rslt=mysql_query($stmtA, $link); if ($reset_hopper == 'Y') @@ -10973,7 +10997,7 @@ if ($ADD==44) $adaptive_maximum_level = '1.0'; $agent_extended_alt_dial = 'N'; $alt_number_dialing = 'N'; - $am_message_exten = '8300'; + $am_message_exten = '8320'; $amd_send_to_vmx = 'N'; $auto_alt_dial = 'N'; $auto_dial_level = '1.0'; @@ -11673,7 +11697,7 @@ if ($ADD==4111) echo "
GROUP MODIFIED: $group_id\n"; - $stmt="UPDATE vicidial_inbound_groups set group_name='$group_name', group_color='$group_color', active='$active', web_form_address='" . mysql_real_escape_string($web_form_address) . "', voicemail_ext='$voicemail_ext', next_agent_call='$next_agent_call', fronter_display='$fronter_display', ingroup_script='$script_id', get_call_launch='$get_call_launch', xferconf_a_dtmf='$xferconf_a_dtmf',xferconf_a_number='$xferconf_a_number', xferconf_b_dtmf='$xferconf_b_dtmf',xferconf_b_number='$xferconf_b_number',drop_action='$drop_action',drop_call_seconds='$drop_call_seconds',drop_exten='$drop_exten',call_time_id='$call_time_id',after_hours_action='$after_hours_action',after_hours_message_filename='$after_hours_message_filename',after_hours_exten='$after_hours_exten',after_hours_voicemail='$after_hours_voicemail',welcome_message_filename='$welcome_message_filename',moh_context='$moh_context',onhold_prompt_filename='$onhold_prompt_filename',prompt_interval='$prompt_interval',agent_alert_exten='$agent_alert_exten',agent_alert_delay='$agent_alert_delay',default_xfer_group='$default_xfer_group',queue_priority='$queue_priority',drop_inbound_group='$drop_inbound_group',ingroup_recording_override='$ingroup_recording_override',ingroup_rec_filename='$ingroup_rec_filename',afterhours_xfer_group='$afterhours_xfer_group',qc_enabled='$qc_enabled',qc_statuses='$QC_statuses',qc_shift_id='$qc_shift_id',qc_get_record_launch='$qc_get_record_launch',qc_show_recording='$qc_show_recording',qc_web_form_address='$qc_web_form_address',qc_script='$qc_script',play_place_in_line='$play_place_in_line',play_estimate_hold_time='$play_estimate_hold_time',hold_time_option='$hold_time_option',hold_time_option_seconds='$hold_time_option_seconds',hold_time_option_exten='$hold_time_option_exten',hold_time_option_voicemail='$hold_time_option_voicemail',hold_time_option_xfer_group='$hold_time_option_xfer_group',hold_time_option_callback_filename='$hold_time_option_callback_filename',hold_time_option_callback_list_id='$hold_time_option_callback_list_id',hold_recall_xfer_group='$hold_recall_xfer_group',no_delay_call_route='$no_delay_call_route',play_welcome_message='$play_welcome_message',answer_sec_pct_rt_stat_one='$answer_sec_pct_rt_stat_one',answer_sec_pct_rt_stat_two='$answer_sec_pct_rt_stat_two',default_group_alias='$default_group_alias',no_agent_no_queue='$no_agent_no_queue',no_agent_action='$no_agent_action',no_agent_action_value='$no_agent_action_value' where group_id='$group_id';"; + $stmt="UPDATE vicidial_inbound_groups set group_name='$group_name', group_color='$group_color', active='$active', web_form_address='" . mysql_real_escape_string($web_form_address) . "', voicemail_ext='$voicemail_ext', next_agent_call='$next_agent_call', fronter_display='$fronter_display', ingroup_script='$script_id', get_call_launch='$get_call_launch', xferconf_a_dtmf='$xferconf_a_dtmf',xferconf_a_number='$xferconf_a_number', xferconf_b_dtmf='$xferconf_b_dtmf',xferconf_b_number='$xferconf_b_number',drop_action='$drop_action',drop_call_seconds='$drop_call_seconds',drop_exten='$drop_exten',call_time_id='$call_time_id',after_hours_action='$after_hours_action',after_hours_message_filename='$after_hours_message_filename',after_hours_exten='$after_hours_exten',after_hours_voicemail='$after_hours_voicemail',welcome_message_filename='$welcome_message_filename',moh_context='$moh_context',onhold_prompt_filename='$onhold_prompt_filename',prompt_interval='$prompt_interval',agent_alert_exten='$agent_alert_exten',agent_alert_delay='$agent_alert_delay',default_xfer_group='$default_xfer_group',queue_priority='$queue_priority',drop_inbound_group='$drop_inbound_group',ingroup_recording_override='$ingroup_recording_override',ingroup_rec_filename='$ingroup_rec_filename',afterhours_xfer_group='$afterhours_xfer_group',qc_enabled='$qc_enabled',qc_statuses='$QC_statuses',qc_shift_id='$qc_shift_id',qc_get_record_launch='$qc_get_record_launch',qc_show_recording='$qc_show_recording',qc_web_form_address='$qc_web_form_address',qc_script='$qc_script',play_place_in_line='$play_place_in_line',play_estimate_hold_time='$play_estimate_hold_time',hold_time_option='$hold_time_option',hold_time_option_seconds='$hold_time_option_seconds',hold_time_option_exten='$hold_time_option_exten',hold_time_option_voicemail='$hold_time_option_voicemail',hold_time_option_xfer_group='$hold_time_option_xfer_group',hold_time_option_callback_filename='$hold_time_option_callback_filename',hold_time_option_callback_list_id='$hold_time_option_callback_list_id',hold_recall_xfer_group='$hold_recall_xfer_group',no_delay_call_route='$no_delay_call_route',play_welcome_message='$play_welcome_message',answer_sec_pct_rt_stat_one='$answer_sec_pct_rt_stat_one',answer_sec_pct_rt_stat_two='$answer_sec_pct_rt_stat_two',default_group_alias='$default_group_alias',no_agent_no_queue='$no_agent_no_queue',no_agent_action='$no_agent_action',no_agent_action_value='$no_agent_action_value',web_form_address_two='" . mysql_real_escape_string($web_form_address_two) . "' where group_id='$group_id';"; $rslt=mysql_query($stmt, $link); ### LOG INSERTION Admin Log Table ### @@ -12853,7 +12877,7 @@ if ($ADD==411111111111111) echo "
VICIDIAL SYSTEM SETTINGS MODIFIED\n"; - $stmt="UPDATE system_settings set use_non_latin='$use_non_latin',webroot_writable='$webroot_writable',enable_queuemetrics_logging='$enable_queuemetrics_logging',queuemetrics_server_ip='$queuemetrics_server_ip',queuemetrics_dbname='$queuemetrics_dbname',queuemetrics_login='$queuemetrics_login',queuemetrics_pass='$queuemetrics_pass',queuemetrics_url='$queuemetrics_url',queuemetrics_log_id='$queuemetrics_log_id',queuemetrics_eq_prepend='$queuemetrics_eq_prepend',vicidial_agent_disable='$vicidial_agent_disable',allow_sipsak_messages='$allow_sipsak_messages',admin_home_url='$admin_home_url',enable_agc_xfer_log='$enable_agc_xfer_log',timeclock_end_of_day='$timeclock_end_of_day',vdc_header_date_format='$vdc_header_date_format',vdc_customer_date_format='$vdc_customer_date_format',vdc_header_phone_format='$vdc_header_phone_format',vdc_agent_api_active='$vdc_agent_api_active',enable_vtiger_integration='$enable_vtiger_integration',vtiger_server_ip='$vtiger_server_ip',vtiger_dbname='$vtiger_dbname',vtiger_login='$vtiger_login',vtiger_pass='$vtiger_pass',vtiger_url='$vtiger_url',qc_features_active='$qc_features_active',outbound_autodial_active='$outbound_autodial_active',outbound_calls_per_second='$outbound_calls_per_second',enable_tts_integration='$enable_tts_integration',agentonly_callback_campaign_lock='$agentonly_callback_campaign_lock',sounds_central_control_active='$sounds_central_control_active',sounds_web_server='$sounds_web_server',sounds_web_directory='$sounds_web_directory',active_voicemail_server='$active_voicemail_server',auto_dial_limit='$auto_dial_limit',user_territories_active='$user_territories_active',allow_custom_dialplan='$allow_custom_dialplan';"; + $stmt="UPDATE system_settings set use_non_latin='$use_non_latin',webroot_writable='$webroot_writable',enable_queuemetrics_logging='$enable_queuemetrics_logging',queuemetrics_server_ip='$queuemetrics_server_ip',queuemetrics_dbname='$queuemetrics_dbname',queuemetrics_login='$queuemetrics_login',queuemetrics_pass='$queuemetrics_pass',queuemetrics_url='$queuemetrics_url',queuemetrics_log_id='$queuemetrics_log_id',queuemetrics_eq_prepend='$queuemetrics_eq_prepend',vicidial_agent_disable='$vicidial_agent_disable',allow_sipsak_messages='$allow_sipsak_messages',admin_home_url='$admin_home_url',enable_agc_xfer_log='$enable_agc_xfer_log',timeclock_end_of_day='$timeclock_end_of_day',vdc_header_date_format='$vdc_header_date_format',vdc_customer_date_format='$vdc_customer_date_format',vdc_header_phone_format='$vdc_header_phone_format',vdc_agent_api_active='$vdc_agent_api_active',enable_vtiger_integration='$enable_vtiger_integration',vtiger_server_ip='$vtiger_server_ip',vtiger_dbname='$vtiger_dbname',vtiger_login='$vtiger_login',vtiger_pass='$vtiger_pass',vtiger_url='$vtiger_url',qc_features_active='$qc_features_active',outbound_autodial_active='$outbound_autodial_active',outbound_calls_per_second='$outbound_calls_per_second',enable_tts_integration='$enable_tts_integration',agentonly_callback_campaign_lock='$agentonly_callback_campaign_lock',sounds_central_control_active='$sounds_central_control_active',sounds_web_server='$sounds_web_server',sounds_web_directory='$sounds_web_directory',active_voicemail_server='$active_voicemail_server',auto_dial_limit='$auto_dial_limit',user_territories_active='$user_territories_active',allow_custom_dialplan='$allow_custom_dialplan',enable_second_webform='$enable_second_webform';"; $rslt=mysql_query($stmt, $link); ### LOG INSERTION Admin Log Table ### @@ -15152,7 +15176,7 @@ if ($ADD==31) $enable_vtiger_integration_LU = $row[0]; $vtiger_url_LU = $row[1]; - $stmt="SELECT campaign_id,campaign_name,active,dial_status_a,dial_status_b,dial_status_c,dial_status_d,dial_status_e,lead_order,park_ext,park_file_name,web_form_address,allow_closers,hopper_level,auto_dial_level,next_agent_call,local_call_time,voicemail_ext,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,amd_send_to_vmx,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,lead_filter_id,drop_call_seconds,drop_action,safe_harbor_exten,display_dialable_count,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,concurrent_transfers,auto_alt_dial,auto_alt_dial_statuses,agent_pause_codes_active,campaign_description,campaign_changedate,campaign_stats_refresh,campaign_logindate,dial_statuses,disable_alter_custdata,no_hopper_leads_logins,list_order_mix,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,xfer_groups,queue_priority,drop_inbound_group,qc_enabled,qc_statuses,qc_lists,qc_shift_id,qc_get_record_launch,qc_show_recording,qc_web_form_address,qc_script,survey_first_audio_file,survey_dtmf_digits,survey_ni_digit,survey_opt_in_audio_file,survey_ni_audio_file,survey_method,survey_no_response_action,survey_ni_status,survey_response_digit_map,survey_xfer_exten,survey_camp_record_dir,disable_alter_custphone,display_queue_count,manual_dial_filter,agent_clipboard_copy,agent_extended_alt_dial,use_campaign_dnc,three_way_call_cid,three_way_dial_prefix,web_form_target,vtiger_search_category,vtiger_create_call_record,vtiger_create_lead_record,vtiger_screen_login,cpd_amd_action,agent_allow_group_alias,default_group_alias,vtiger_search_dead,vtiger_status_call,survey_third_digit,survey_third_audio_file,survey_third_status,survey_third_exten,survey_fourth_digit,survey_fourth_audio_file,survey_fourth_status,survey_fourth_exten,drop_lockout_time,quick_transfer_button,prepopulate_transfer_preset,drop_rate_group,view_calls_in_queue,view_calls_in_queue_launch,grab_calls_in_queue,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads from vicidial_campaigns where campaign_id='$campaign_id';"; + $stmt="SELECT campaign_id,campaign_name,active,dial_status_a,dial_status_b,dial_status_c,dial_status_d,dial_status_e,lead_order,park_ext,park_file_name,web_form_address,allow_closers,hopper_level,auto_dial_level,next_agent_call,local_call_time,voicemail_ext,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,amd_send_to_vmx,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,lead_filter_id,drop_call_seconds,drop_action,safe_harbor_exten,display_dialable_count,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,concurrent_transfers,auto_alt_dial,auto_alt_dial_statuses,agent_pause_codes_active,campaign_description,campaign_changedate,campaign_stats_refresh,campaign_logindate,dial_statuses,disable_alter_custdata,no_hopper_leads_logins,list_order_mix,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,xfer_groups,queue_priority,drop_inbound_group,qc_enabled,qc_statuses,qc_lists,qc_shift_id,qc_get_record_launch,qc_show_recording,qc_web_form_address,qc_script,survey_first_audio_file,survey_dtmf_digits,survey_ni_digit,survey_opt_in_audio_file,survey_ni_audio_file,survey_method,survey_no_response_action,survey_ni_status,survey_response_digit_map,survey_xfer_exten,survey_camp_record_dir,disable_alter_custphone,display_queue_count,manual_dial_filter,agent_clipboard_copy,agent_extended_alt_dial,use_campaign_dnc,three_way_call_cid,three_way_dial_prefix,web_form_target,vtiger_search_category,vtiger_create_call_record,vtiger_create_lead_record,vtiger_screen_login,cpd_amd_action,agent_allow_group_alias,default_group_alias,vtiger_search_dead,vtiger_status_call,survey_third_digit,survey_third_audio_file,survey_third_status,survey_third_exten,survey_fourth_digit,survey_fourth_audio_file,survey_fourth_status,survey_fourth_exten,drop_lockout_time,quick_transfer_button,prepopulate_transfer_preset,drop_rate_group,view_calls_in_queue,view_calls_in_queue_launch,grab_calls_in_queue,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads,web_form_address_two,waitforsilence_options from vicidial_campaigns where campaign_id='$campaign_id';"; $rslt=mysql_query($stmt, $link); $row=mysql_fetch_row($rslt); $campaign_name = $row[1]; @@ -15279,6 +15303,8 @@ if ($ADD==31) $no_hopper_dialing = $row[125]; $agent_dial_owner_only = $row[126]; $agent_display_dialable_leads = $row[127]; + $web_form_address_two = $row[128]; + $waitforsilence_options = $row[129]; if (ereg("DISABLED",$list_order_mix)) {$DEFlistDISABLE = ''; $DEFstatusDISABLED=0;} @@ -15512,7 +15538,11 @@ if ($ADD==31) echo "Campaign Login Date: $campaign_logindate   $NWB#vicidial_campaigns-campaign_logindate$NWE\n"; echo "Active: $NWB#vicidial_campaigns-active$NWE\n"; echo "Park Extension: - Filename: $NWB#vicidial_campaigns-park_ext$NWE\n"; - echo "Web Form: $NWB#vicidial_campaigns-web_form_address$NWE\n"; + echo "Web Form: $NWB#vicidial_campaigns-web_form_address$NWE\n"; + if ($SSenable_second_webform > 0) + { + echo "Web Form Two: $NWB#vicidial_campaigns-web_form_address$NWE\n"; + } echo "Web Form Target: $NWB#vicidial_campaigns-web_form_target$NWE\n"; echo "Allow Closers: $NWB#vicidial_campaigns-allow_closers$NWE\n"; @@ -15881,7 +15911,9 @@ if ($ADD==31) echo "Get Call Launch: $NWB#vicidial_campaigns-get_call_launch$NWE\n"; - echo "Answering Machine Message: $NWB#vicidial_campaigns-am_message_exten$NWE\n"; + echo "Answering Machine Message:
audio chooser $NWB#vicidial_campaigns-am_message_exten$NWE\n"; + + echo "WaitForSilence Options: $NWB#vicidial_campaigns-waitforsilence_options$NWE\n"; if ($SSoutbound_autodial_active > 0) { @@ -18384,7 +18416,7 @@ if ($ADD==3111) echo "\n"; echo "\n"; echo "\n"; - echo "\n"; + echo "\n"; + if ($SSenable_second_webform > 0) + { + echo "\n"; + } echo "\n"; echo "
\n"; echo ""; - $stmt="SELECT * from vicidial_inbound_groups where group_id='$group_id';"; + $stmt="SELECT group_id,group_name,group_color,active,web_form_address,voicemail_ext,next_agent_call,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,drop_call_seconds,drop_action,drop_exten,call_time_id,after_hours_action,after_hours_message_filename,after_hours_exten,after_hours_voicemail,welcome_message_filename,moh_context,onhold_prompt_filename,prompt_interval,agent_alert_exten,agent_alert_delay,default_xfer_group,queue_priority,drop_inbound_group,ingroup_recording_override,ingroup_rec_filename,afterhours_xfer_group,qc_enabled,qc_statuses,qc_shift_id,qc_get_record_launch,qc_show_recording,qc_web_form_address,qc_script,play_place_in_line,play_estimate_hold_time,hold_time_option,hold_time_option_seconds,hold_time_option_exten,hold_time_option_voicemail,hold_time_option_xfer_group,hold_time_option_callback_filename,hold_time_option_callback_list_id,hold_recall_xfer_group,no_delay_call_route,play_welcome_message,answer_sec_pct_rt_stat_one,answer_sec_pct_rt_stat_two,default_group_alias,no_agent_no_queue,no_agent_action,no_agent_action_value,web_form_address_two from vicidial_inbound_groups where group_id='$group_id';"; $rslt=mysql_query($stmt, $link); $row=mysql_fetch_row($rslt); $group_name = $row[1]; @@ -18445,6 +18477,7 @@ if ($ADD==3111) $no_agent_no_queue = $row[56]; $no_agent_action = $row[57]; $no_agent_action_value = $row[58]; + $web_form_address_two = stripslashes($row[59]); ##### get in-groups listings for dynamic pulldown $stmt="SELECT group_id,group_name from vicidial_inbound_groups where group_id NOT IN('AGENTDIRECT') order by group_id"; @@ -18534,7 +18567,11 @@ if ($ADD==3111) echo "
Group Name: $NWB#vicidial_inbound_groups-group_name$NWE
Group Color: $NWB#vicidial_inbound_groups-group_color$NWE
Active: $NWB#vicidial_inbound_groups-active$NWE
Web Form: $NWB#vicidial_inbound_groups-web_form_address$NWE
Web Form: $NWB#vicidial_inbound_groups-web_form_address$NWE
Web Form Two: $NWB#vicidial_inbound_groups-web_form_address$NWE
Next Agent Call: $NWB#vicidial_inbound_groups-next_agent_call$NWE
Queue Priority:
\n"; echo ""; - $stmt="SELECT version,install_date,use_non_latin,webroot_writable,enable_queuemetrics_logging,queuemetrics_server_ip,queuemetrics_dbname,queuemetrics_login,queuemetrics_pass,queuemetrics_url,queuemetrics_log_id,queuemetrics_eq_prepend,vicidial_agent_disable,allow_sipsak_messages,admin_home_url,enable_agc_xfer_log,db_schema_version,auto_user_add_value,timeclock_end_of_day,timeclock_last_reset_date,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,vdc_agent_api_active,qc_last_pull_time,enable_vtiger_integration,vtiger_server_ip,vtiger_dbname,vtiger_login,vtiger_pass,vtiger_url,qc_features_active,outbound_autodial_active,outbound_calls_per_second,enable_tts_integration,agentonly_callback_campaign_lock,sounds_central_control_active,sounds_web_server,sounds_web_directory,active_voicemail_server,auto_dial_limit,user_territories_active,allow_custom_dialplan from system_settings;"; + $stmt="SELECT version,install_date,use_non_latin,webroot_writable,enable_queuemetrics_logging,queuemetrics_server_ip,queuemetrics_dbname,queuemetrics_login,queuemetrics_pass,queuemetrics_url,queuemetrics_log_id,queuemetrics_eq_prepend,vicidial_agent_disable,allow_sipsak_messages,admin_home_url,enable_agc_xfer_log,db_schema_version,auto_user_add_value,timeclock_end_of_day,timeclock_last_reset_date,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,vdc_agent_api_active,qc_last_pull_time,enable_vtiger_integration,vtiger_server_ip,vtiger_dbname,vtiger_login,vtiger_pass,vtiger_url,qc_features_active,outbound_autodial_active,outbound_calls_per_second,enable_tts_integration,agentonly_callback_campaign_lock,sounds_central_control_active,sounds_web_server,sounds_web_directory,active_voicemail_server,auto_dial_limit,user_territories_active,allow_custom_dialplan,db_schema_update_date,enable_second_webform from system_settings;"; $rslt=mysql_query($stmt, $link); $row=mysql_fetch_row($rslt); $version = $row[0]; @@ -21251,6 +21288,8 @@ if ($ADD==311111111111111) $auto_dial_limit = $row[40]; $user_territories_active = $row[41]; $allow_custom_dialplan = $row[42]; + $db_schema_update_date = $row[43]; + $enable_second_webform = $row[44]; echo "
MODIFY VICIDIAL SYSTEM SETTINGS
\n"; echo "\n"; @@ -21258,6 +21297,7 @@ if ($ADD==311111111111111) echo "
\n"; echo "\n"; echo "\n"; + echo "\n"; echo "\n"; echo "\n"; echo "\n"; @@ -21392,6 +21432,8 @@ if ($ADD==311111111111111) echo "\n"; + echo "\n"; + echo "\n"; echo "\n";
Version: $version
DB Schema Version: $db_schema_version
DB Schema Update Date: $db_schema_update_date
Auto User-add Value: $auto_user_add_value
Install Date: $install_date
Use Non-Latin: $NWB#settings-use_non_latin$NWE
User Territories Active: $NWB#settings-user_territories_active$NWE
Enable Second Webform: $NWB#settings-enable_second_webform$NWE
Enable TTS Integration: $NWB#settings-enable_tts_integration$NWE
QC Features Active: $NWB#settings-qc_features_active$NWE