diff --git a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/conf_exten_check.php b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/conf_exten_check.php index 47ec7fe6..474ce8a4 100644 --- a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/conf_exten_check.php +++ b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/conf_exten_check.php @@ -36,6 +36,7 @@ # 70319-1542 - Added agent disabled display function # 71122-0205 - Added vicidial_live_agent status output # 80424-0442 - Added non_latin lookup from system_settings +# 80519-1425 - Added calls-in-queue tally # require("dbconnect.php"); @@ -64,6 +65,10 @@ if (isset($_GET["auto_dial_level"])) {$auto_dial_level=$_GET["auto_dial_level" if (isset($_GET["campagentstdisp"])) {$campagentstdisp=$_GET["campagentstdisp"];} elseif (isset($_POST["campagentstdisp"])) {$campagentstdisp=$_POST["campagentstdisp"];} +header ("Content-type: text/html; charset=utf-8"); +header ("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 +header ("Pragma: no-cache"); // HTTP/1.0 + ############################################# ##### START SYSTEM_SETTINGS LOOKUP ##### @@ -92,6 +97,10 @@ if (!isset($format)) {$format="text";} if (!isset($ACTION)) {$ACTION="refresh";} if (!isset($client)) {$client="agc";} +$Alogin='N'; +$RingCalls='N'; +$DiaLCalls='N'; + $version = '2.0.4-12'; $build = '71122-0205'; $StarTtime = date("U"); @@ -203,30 +212,45 @@ echo "
if ($campagentstdisp == 'YES') { ### grab the status of this agent to display - $stmt="SELECT status,campaign_id from vicidial_live_agents where user='$user' and server_ip='$server_ip';"; + $stmt="SELECT status,campaign_id,closer_campaigns from vicidial_live_agents where user='$user' and server_ip='$server_ip';"; if ($DB) {echo "|$stmt|\n";} $rslt=mysql_query($stmt, $link); $row=mysql_fetch_row($rslt); $Alogin=$row[0]; $Acampaign=$row[1]; + $AccampSQL=$row[2]; + $AccampSQL = ereg_replace(' -','', $AccampSQL); + $AccampSQL = ereg_replace(' ',"','", $AccampSQL); ### grab the number of calls being placed from this server and campaign - $stmt="SELECT count(*) from vicidial_auto_calls where server_ip='$server_ip' and status NOT IN('XFER') and campaign_id='$Acampaign';"; + $stmt="SELECT count(*) from vicidial_auto_calls where status IN('LIVE') and ( (campaign_id='$Acampaign') or (campaign_id IN('$AccampSQL')) );"; if ($DB) {echo "|$stmt|\n";} $rslt=mysql_query($stmt, $link); $row=mysql_fetch_row($rslt); $RingCalls=$row[0]; + if ($RingCalls > 0) {$RingCalls = "Calls in Queue: $RingCalls";} + else {$RingCalls = "Calls in Queue: $RingCalls";} + + ### grab the number of calls being placed from this server and campaign + $stmt="SELECT count(*) from vicidial_auto_calls where status NOT IN('XFER') and ( (campaign_id='$Acampaign') or (campaign_id IN('$AccampSQL')) );"; + if ($DB) {echo "|$stmt|\n";} + $rslt=mysql_query($stmt, $link); + $row=mysql_fetch_row($rslt); + $DiaLCalls=$row[0]; + } else { $Alogin='N'; $RingCalls='N'; + $DiaLCalls='N'; } } else { $Alogin='N'; $RingCalls='N'; + $DiaLCalls='N'; ### update the vicidial_live_agents every second with a new random number so it is shown to be alive $stmt="UPDATE vicidial_live_agents set random_id='$random' where user='$user' and server_ip='$server_ip';"; @@ -238,7 +262,7 @@ echo " if ($Acount < 1) {$Alogin='DEAD_VLA';} if ($AexternalDEAD > 0) {$Alogin='DEAD_EXTERNAL';} - echo 'DateTime: ' . $NOW_TIME . '|UnixTime: ' . $StarTtime . '|Logged-in: ' . $Alogin . '|CampCalls: ' . $RingCalls . '|Status: ' . $Astatus . "|\n"; + echo 'DateTime: ' . $NOW_TIME . '|UnixTime: ' . $StarTtime . '|Logged-in: ' . $Alogin . '|CampCalls: ' . $RingCalls . '|Status: ' . $Astatus . '|DiaLCalls: ' . $DiaLCalls . "|\n"; } $total_conf=0; diff --git a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/manager_send.php b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/manager_send.php index e3e53530..6b322a41 100644 --- a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/manager_send.php +++ b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/manager_send.php @@ -146,6 +146,10 @@ if (isset($_GET["allow_sipsak_messages"])) {$allow_sipsak_messages=$_GET["all if (isset($_GET["session_id"])) {$session_id=$_GET["session_id"];} elseif (isset($_POST["session_id"])) {$session_id=$_POST["session_id"];} +header ("Content-type: text/html; charset=utf-8"); +header ("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 +header ("Pragma: no-cache"); // HTTP/1.0 + ############################################# ##### START SYSTEM_SETTINGS LOOKUP ##### $stmt = "SELECT use_non_latin FROM system_settings;"; diff --git a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vdc_db_query.php b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vdc_db_query.php index 2cf95474..253ec880 100644 --- a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vdc_db_query.php +++ b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vdc_db_query.php @@ -611,7 +611,7 @@ if ($ACTION == 'manDiaLnextCaLL') else { ### grab the next lead in the hopper for this campaign and reserve it for the user - $stmt = "UPDATE vicidial_hopper set status='QUEUE', user='$user' where campaign_id='$campaign' and status='READY' order by hopper_id LIMIT 1"; + $stmt = "UPDATE vicidial_hopper set status='QUEUE', user='$user' where campaign_id='$campaign' and status='READY' order by priority desc,hopper_id LIMIT 1"; if ($DB) {echo "$stmt\n";} $rslt=mysql_query($stmt, $link); $affected_rows = mysql_affected_rows($link); @@ -668,7 +668,7 @@ if ($ACTION == 'manDiaLnextCaLL') $alt_phone = trim("$row[26]"); $email = trim("$row[27]"); $security = trim("$row[28]"); - $comments = trim("$row[29]"); + $comments = stripslashes(trim("$row[29]")); $called_count = trim("$row[30]"); } @@ -1631,7 +1631,7 @@ if ($ACTION == 'VDADcheckINCOMING') $alt_phone = trim("$row[26]"); $email = trim("$row[27]"); $security = trim("$row[28]"); - $comments = trim("$row[29]"); + $comments = stripslashes(trim("$row[29]")); $called_count = trim("$row[30]"); } diff --git a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vicidial.php b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vicidial.php index 0d24d76e..862f2936 100644 --- a/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vicidial.php +++ b/agc_2-X/branches/agc_2.0.4/LANG_www/agc/vicidial.php @@ -174,10 +174,13 @@ # 71226-1117 - added option to kick all calls from conference upon logout # 80330-0823 - Added new AST_blind monitoring ability and minor cleanup for release # 80402-0121 - Fixes for Manual Dial hangups and transfers +# 80428-0413 - UTF8 changes and testing +# 80507-0932 - Fixed Script display bug (+ instead of space) +# 80519-1425 - Added calls in queue display # -$version = '2.0.4-145'; -$build = '80402-0121'; +$version = '2.0.4-148'; +$build = '80519-1425'; require("dbconnect.php"); @@ -269,8 +272,9 @@ $multi_line_comments = '1'; # set to 1 to allow multi-line comment box $user_login_first = '0'; # set to 1 to have the vicidial_user login before the phone login $view_scripts = '1'; # set to 1 to show the SCRIPTS tab $dispo_check_all_pause = '0'; # set to 1 to allow for persistent pause after dispo -$agentcallsstatus = '0'; # set to 1 to show agent status and call count - $campagentstatctmax = '0'; # Number of seconds for campaign call and agent stats +$callholdstatus = '1'; # set to 1 to show calls on hold count +$agentcallsstatus = '0'; # set to 1 to show agent status and call dialed count + $campagentstatctmax = '3'; # Number of seconds for campaign call and agent stats $show_campname_pulldown = '1'; # set to 1 to show campaign name on login pulldown $webform_sessionname = '1'; # set to 1 to include the session_name in webform URL $local_consult_xfers = '1'; # set to 1 to send consultative transfers from original server @@ -1763,6 +1767,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var AgainCalLSecondS = ''; var AgaiNCalLCID = ''; var CB_count_check = 60; + var callholdstatus = ' echo $callholdstatus ?>' var agentcallsstatus = ' echo $agentcallsstatus ?>' var campagentstatctmax = ' echo $campagentstatctmax ?>' var campagentstatct = '0'; @@ -1771,6 +1776,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var reselect_preview_dial = 0; var reselect_alt_dial = 0; var alt_dial_active = 0; + var alt_dial_status_display = 0; var mdnLisT_id = ' echo $manual_dial_list_id ?>'; var VU_vicidial_transfers = ' echo $VU_vicidial_transfers ?>'; var agentonly_callbacks = ' echo $agentonly_callbacks ?>'; @@ -2206,7 +2212,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} if (typeof(xmlhttprequestcheckconf) == "undefined") { //alert (xmlhttprequestcheckconf == xmlhttpSendConf); custchannellive--; - if (agentcallsstatus == '1') + if ( (agentcallsstatus == '1') || (callholdstatus == '1') ) { campagentstatct++; if (campagentstatct > campagentstatctmax) @@ -2266,12 +2272,14 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} UnixTime = parseInt(UnixTime); UnixTimeMS = (UnixTime * 1000); t.setTime(UnixTimeMS); - if ( (agentcallsstatus == '1') || (vicidial_agent_disable != 'NOT_ACTIVE') ) + if ( (callholdstatus == '1') || (agentcallsstatus == '1') || (vicidial_agent_disable != 'NOT_ACTIVE') ) { var Alogin_array = check_time_array[2].split("Logged-in: "); var AGLogiN = Alogin_array[1]; var CamPCalLs_array = check_time_array[3].split("CampCalls: "); var CamPCalLs = CamPCalLs_array[1]; + var DiaLCalLs_array = check_time_array[5].split("DiaLCalls: "); + var DiaLCalLs = DiaLCalLs_array[1]; if (AGLogiN != 'N') { document.getElementById("AgentStatusStatus").innerHTML = AGLogiN; @@ -2280,6 +2288,10 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} { document.getElementById("AgentStatusCalls").innerHTML = CamPCalLs; } + if (DiaLCalLs != 'N') + { + document.getElementById("AgentStatusDiaLs").innerHTML = DiaLCalLs; + } if ( (AGLogiN == 'DEAD_VLA') && ( (vicidial_agent_disable == 'LIVE_AGENT') || (vicidial_agent_disable == 'ALL') ) ) { showDiv('AgenTDisablEBoX'); @@ -2804,6 +2816,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} { alt_phone_dialing=starting_alt_phone_dialing; alt_dial_active = 0; + alt_dial_status_display = 0; open_dispo_screen=1; document.getElementById("MainStatuSSpan").innerHTML = "Dial Next Number"; } @@ -2820,6 +2833,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} { reselect_alt_dial = 1; alt_dial_active = 1; + alt_dial_status_display = 1; var man_status = "Dial Alt Phone Number: MAIN PHONE or ALT PHONE or ADDRESS3 or FINISH LEAD"; document.getElementById("MainStatuSSpan").innerHTML = man_status; } @@ -3001,7 +3015,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";} var CB_calls = all_CBs_array[0]; var loop_ct=0; var conv_start=0; - var CB_HTML = "