Added adaptive_percentmax_percentage campaign option and ADAPT_PERCENTMAX dial_method, fix for dropped cached counts

git-svn-id: svn://192.168.202.10@3957 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2025-12-11 19:14:23 +00:00
parent c05c3689f2
commit 93528c6e20
12 changed files with 97 additions and 33 deletions
+2
View File
@@ -894,6 +894,8 @@ OTHER CHANGES:
for level 9 users if crashed tables are found. Enabled by default, for level 9 users if crashed tables are found. Enabled by default,
configurable in the System Settings. configurable in the System Settings.
255. Added ADAPT_PERCENTMAX Dial Method campaign option.
+31 -5
View File
@@ -63,9 +63,10 @@
# 240219-1514 - Added vicidial_live_inbound_agents.daily_limit parameter # 240219-1514 - Added vicidial_live_inbound_agents.daily_limit parameter
# 250131-1624 - Modifications to fix cached hour counts for realtime report # 250131-1624 - Modifications to fix cached hour counts for realtime report
# 250218-1613 - Modified master loop to use microseconds instead of a counter to execute drop/dial level/shared dialing functions # 250218-1613 - Modified master loop to use microseconds instead of a counter to execute drop/dial level/shared dialing functions
# 251205-0949 - Added adaptive_percentmax_percentage option and ADAPT_PERCENTMAX dial_method, fix for dropped cached counts
# #
$build='250218-1613'; $build='251205-0949';
# constants # constants
$DB=0; # Debug flag, set to 0 for no debug messages, On an active system this will generate lots of lines of output per minute $DB=0; # Debug flag, set to 0 for no debug messages, On an active system this will generate lots of lines of output per minute
$US='__'; $US='__';
@@ -491,6 +492,7 @@ while ($master_loop < $CLIloops)
@adaptive_latest_server_time=@MT; @adaptive_latest_server_time=@MT;
@adaptive_intensity=@MT; @adaptive_intensity=@MT;
@adaptive_dl_diff_target=@MT; @adaptive_dl_diff_target=@MT;
@adaptive_percentmax_percentage=@MT;
@campaign_changedate=@MT; @campaign_changedate=@MT;
@campaign_stats_refresh=@MT; @campaign_stats_refresh=@MT;
@campaign_allow_inbound=@MT; @campaign_allow_inbound=@MT;
@@ -503,11 +505,11 @@ while ($master_loop < $CLIloops)
if ($CLIcampaign) if ($CLIcampaign)
{ {
$stmtA = "SELECT campaign_id,lead_order,hopper_level,auto_dial_level,local_call_time,lead_filter_id,use_internal_dnc,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,UNIX_TIMESTAMP(campaign_changedate),campaign_stats_refresh,campaign_allow_inbound,drop_rate_group,UNIX_TIMESTAMP(campaign_calldate),realtime_agent_time_stats,available_only_tally_threshold,available_only_tally_threshold_agents,dial_level_threshold,dial_level_threshold_agents,ofcom_uk_drop_calc,drop_call_seconds,drop_action,drop_inbound_group,incall_tally_threshold_seconds from vicidial_campaigns where campaign_id='$CLIcampaign'"; $stmtA = "SELECT campaign_id,lead_order,hopper_level,auto_dial_level,local_call_time,lead_filter_id,use_internal_dnc,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,UNIX_TIMESTAMP(campaign_changedate),campaign_stats_refresh,campaign_allow_inbound,drop_rate_group,UNIX_TIMESTAMP(campaign_calldate),realtime_agent_time_stats,available_only_tally_threshold,available_only_tally_threshold_agents,dial_level_threshold,dial_level_threshold_agents,ofcom_uk_drop_calc,drop_call_seconds,drop_action,drop_inbound_group,incall_tally_threshold_seconds,adaptive_percentmax_percentage from vicidial_campaigns where campaign_id='$CLIcampaign'";
} }
else else
{ {
$stmtA = "SELECT campaign_id,lead_order,hopper_level,auto_dial_level,local_call_time,lead_filter_id,use_internal_dnc,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,UNIX_TIMESTAMP(campaign_changedate),campaign_stats_refresh,campaign_allow_inbound,drop_rate_group,UNIX_TIMESTAMP(campaign_calldate),realtime_agent_time_stats,available_only_tally_threshold,available_only_tally_threshold_agents,dial_level_threshold,dial_level_threshold_agents,ofcom_uk_drop_calc,drop_call_seconds,drop_action,drop_inbound_group,incall_tally_threshold_seconds from vicidial_campaigns where ( (active='Y') or (campaign_stats_refresh='Y') )"; $stmtA = "SELECT campaign_id,lead_order,hopper_level,auto_dial_level,local_call_time,lead_filter_id,use_internal_dnc,dial_method,available_only_ratio_tally,adaptive_dropped_percentage,adaptive_maximum_level,adaptive_latest_server_time,adaptive_intensity,adaptive_dl_diff_target,UNIX_TIMESTAMP(campaign_changedate),campaign_stats_refresh,campaign_allow_inbound,drop_rate_group,UNIX_TIMESTAMP(campaign_calldate),realtime_agent_time_stats,available_only_tally_threshold,available_only_tally_threshold_agents,dial_level_threshold,dial_level_threshold_agents,ofcom_uk_drop_calc,drop_call_seconds,drop_action,drop_inbound_group,incall_tally_threshold_seconds,adaptive_percentmax_percentage from vicidial_campaigns where ( (active='Y') or (campaign_stats_refresh='Y') )";
} }
$sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr;
$sthA->execute or die "executing: $stmtA ", $dbhA->errstr; $sthA->execute or die "executing: $stmtA ", $dbhA->errstr;
@@ -548,6 +550,7 @@ while ($master_loop < $CLIloops)
$drop_action[$rec_count] = $aryA[26]; $drop_action[$rec_count] = $aryA[26];
$drop_inbound_group[$rec_count] = $aryA[27]; $drop_inbound_group[$rec_count] = $aryA[27];
$incall_tally_threshold_seconds[$rec_count] = $aryA[28]; $incall_tally_threshold_seconds[$rec_count] = $aryA[28];
$adaptive_percentmax_percentage[$rec_count] = $aryA[29];
$rec_count++; $rec_count++;
} }
@@ -2777,7 +2780,7 @@ sub shared_agent_process
$camp_SHARED_SQL=''; $camp_SHARED_SQL='';
$drop_SHARED_SQL=''; $drop_SHARED_SQL='';
# Get list of active SHARED_ campaigns # Get list of active SHARED_ campaigns
$stmtA = "SELECT campaign_id,drop_inbound_group from vicidial_campaigns where active='Y' and dial_method IN('SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE');"; $stmtA = "SELECT campaign_id,drop_inbound_group from vicidial_campaigns where active='Y' and dial_method IN('SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX');";
$sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr;
$sthA->execute or die "executing: $stmtA ", $dbhA->errstr; $sthA->execute or die "executing: $stmtA ", $dbhA->errstr;
$sthArows=$sthA->rows; $sthArows=$sthA->rows;
@@ -3864,6 +3867,7 @@ sub calculate_drops
{ {
@aryA = $sthA->fetchrow_array; @aryA = $sthA->fetchrow_array;
$VL_this_hour_calls = $aryA[0]; $VL_this_hour_calls = $aryA[0];
$VCSdrops_today[$i] = ($VCSdrops_today[$i] + $VL_this_hour_calls);
} }
$sthA->finish(); $sthA->finish();
if ($DBX) {print "VCHC CACHED HOUR QUERY: |$sthArows|$VL_this_hour_calls|$stmtA|\n";} if ($DBX) {print "VCHC CACHED HOUR QUERY: |$sthArows|$VL_this_hour_calls|$stmtA|\n";}
@@ -6901,7 +6905,7 @@ sub calculate_dial_level
$differential_onemin[$i] = $stat_differential[$i]; $differential_onemin[$i] = $stat_differential[$i];
} }
if ( ($dial_method[$i] =~ /ADAPT_HARD_LIMIT|ADAPT_AVERAGE|ADAPT_TAPERED/) || ($force_test>0) ) if ( ($dial_method[$i] =~ /ADAPT_HARD_LIMIT|ADAPT_AVERAGE|ADAPT_TAPERED|ADAPT_PERCENTMAX/) || ($force_test>0) )
{ {
# Calculate the optimal dial_level differential for the past minute # Calculate the optimal dial_level differential for the past minute
$differential_target[$i] = ($differential_onemin[$i] + $adaptive_dl_diff_target[$i]); $differential_target[$i] = ($differential_onemin[$i] + $adaptive_dl_diff_target[$i]);
@@ -6955,6 +6959,7 @@ sub calculate_dial_level
$adaptive_string .= " SERVER TIME: $current_hourmin\n"; $adaptive_string .= " SERVER TIME: $current_hourmin\n";
$adaptive_string .= " LATE TARGET: $last_target_hour_final[$i] ($tapered_hours_left[$i] left|$tapered_rate[$i])\n"; $adaptive_string .= " LATE TARGET: $last_target_hour_final[$i] ($tapered_hours_left[$i] left|$tapered_rate[$i])\n";
$adaptive_string .= " INTENSITY: $adaptive_intensity[$i]\n"; $adaptive_string .= " INTENSITY: $adaptive_intensity[$i]\n";
$adaptive_string .= " PCT-MAX PCT: $adaptive_percentmax_percentage[$i]\n";
$adaptive_string .= " DLDIFF TARGET: $adaptive_dl_diff_target[$i]\n"; $adaptive_string .= " DLDIFF TARGET: $adaptive_dl_diff_target[$i]\n";
$adaptive_string .= "CURRENT STATS-\n"; $adaptive_string .= "CURRENT STATS-\n";
$adaptive_string .= " AVG AGENTS: $agents_average_onemin[$i]\n"; $adaptive_string .= " AVG AGENTS: $agents_average_onemin[$i]\n";
@@ -7014,6 +7019,27 @@ sub calculate_dial_level
$adaptive_string .= " DROP RATE OVER LIMIT FOR TODAY! TAPERING DIAL LEVEL TO: $intensity_dial_level[$i]\n"; $adaptive_string .= " DROP RATE OVER LIMIT FOR TODAY! TAPERING DIAL LEVEL TO: $intensity_dial_level[$i]\n";
} }
} }
if ($dial_method[$i] =~ /ADAPT_PERCENTMAX/)
{
$temp_new_dial_level = sprintf("%.3f", ( ($adaptive_percentmax_percentage[$i] * $adaptive_maximum_level[$i]) / 100));
if ($temp_new_dial_level > $intensity_dial_level[$i])
{
$adaptive_string .= " DROP RATE OVER LAST HOUR LIMIT FOR TODAY! PERCENT-MAX DIAL LEVEL GREATER THAN CURRENT DIAL LEVEL, DOING NOTHING ($temp_new_dial_level > $intensity_dial_level[$i] |$adaptive_percentmax_percentage[$i]|$adaptive_maximum_level[$i])\n";
}
else
{
if ($temp_new_dial_level < 1)
{
$intensity_dial_level[$i] = "1.0";
$adaptive_string .= " DROP RATE OVER LAST HOUR LIMIT FOR TODAY! PERCENT-MAX LESS THAN 1, DIAL LEVEL TO: 1.0 ($temp_new_dial_level|$adaptive_percentmax_percentage[$i]|$adaptive_maximum_level[$i])\n";
}
else
{
$adaptive_string .= " DROP RATE OVER LIMIT FOR TODAY! PERCENT-MAX DIAL LEVEL TO: $temp_new_dial_level ($adaptive_percentmax_percentage[$i]|$adaptive_maximum_level[$i]) from $intensity_dial_level[$i]\n";
$intensity_dial_level[$i] = $temp_new_dial_level;
}
}
}
} }
### BEGIN Dial Level Threshold Check ### ### BEGIN Dial Level Threshold Check ###
+4 -3
View File
@@ -25,7 +25,7 @@
# It is good practice to keep this program running by placing the associated # It is good practice to keep this program running by placing the associated
# KEEPALIVE script running every minute to ensure this program is always running # KEEPALIVE script running every minute to ensure this program is always running
# #
# Copyright (C) 2024 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2 # Copyright (C) 2025 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2
# #
# CHANGELOG: # CHANGELOG:
# 50125-1201 - Changed dial timeout to 120 seconds from 180 seconds # 50125-1201 - Changed dial timeout to 120 seconds from 180 seconds
@@ -161,9 +161,10 @@
# 240225-0951 - Added AUTONEXT hopper_hold_inserts option # 240225-0951 - Added AUTONEXT hopper_hold_inserts option
# 240731-0814 - Fix for 2nd DB connection timing out while running # 240731-0814 - Fix for 2nd DB connection timing out while running
# 240917-1719 - Change multiple after-call processing to only run for active_voicemail_server # 240917-1719 - Change multiple after-call processing to only run for active_voicemail_server
# 251205-1455 - Added SHARED_ADAPT_PERCENTMAX option
# #
$build='240917-1719'; $build='251205-1455';
$script='AST_VDauto_dial'; $script='AST_VDauto_dial';
### begin parsing run-time options ### ### begin parsing run-time options ###
if (length($ARGV[0])>1) if (length($ARGV[0])>1)
@@ -582,7 +583,7 @@ while($one_day_interval > 0)
$agent_shared_campaigns_ct=0; $agent_shared_campaigns_ct=0;
if ($allow_shared_dial > 0) if ($allow_shared_dial > 0)
{ {
$stmtA = "SELECT campaign_id,drop_inbound_group,shared_dial_rank,auto_dial_level FROM vicidial_campaigns where active='Y' and dial_method IN('SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE') order by shared_dial_rank desc;"; $stmtA = "SELECT campaign_id,drop_inbound_group,shared_dial_rank,auto_dial_level FROM vicidial_campaigns where active='Y' and dial_method IN('SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX') order by shared_dial_rank desc;";
$sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr; $sthA = $dbhA->prepare($stmtA) or die "preparing: ",$dbhA->errstr;
$sthA->execute or die "executing: $stmtA ", $dbhA->errstr; $sthA->execute or die "executing: $stmtA ", $dbhA->errstr;
$sthArows=$sthA->rows; $sthArows=$sthA->rows;
@@ -824,7 +824,7 @@ closer_campaigns TEXT,
use_internal_dnc ENUM('Y','N','AREACODE') default 'N', use_internal_dnc ENUM('Y','N','AREACODE') default 'N',
allcalls_delay SMALLINT(3) UNSIGNED default '0', allcalls_delay SMALLINT(3) UNSIGNED default '0',
omit_phone_code ENUM('Y','N') default 'N', omit_phone_code ENUM('Y','N') default 'N',
dial_method ENUM('MANUAL','RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','INBOUND_MAN','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE') default 'MANUAL', dial_method ENUM('MANUAL','RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','INBOUND_MAN','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX') default 'MANUAL',
available_only_ratio_tally ENUM('Y','N') default 'N', available_only_ratio_tally ENUM('Y','N') default 'N',
adaptive_dropped_percentage VARCHAR(4) default '3', adaptive_dropped_percentage VARCHAR(4) default '3',
adaptive_maximum_level VARCHAR(6) default '3.0', adaptive_maximum_level VARCHAR(6) default '3.0',
@@ -1143,7 +1143,8 @@ parallel_rec_cm_filename VARCHAR(50) default '',
parallel_rec_fr_filename VARCHAR(50) default '', parallel_rec_fr_filename VARCHAR(50) default '',
recording_dtmf_muting SMALLINT(3) UNSIGNED default '0', recording_dtmf_muting SMALLINT(3) UNSIGNED default '0',
stereo_recording_agent ENUM('NEVER','ONDEMAND','ALLCALLS','ALLFORCE') default 'ALLFORCE', stereo_recording_agent ENUM('NEVER','ONDEMAND','ALLCALLS','ALLFORCE') default 'ALLFORCE',
call_count_limit_restrict VARCHAR(30) default 'DISABLED' call_count_limit_restrict VARCHAR(30) default 'DISABLED',
adaptive_percentmax_percentage TINYINT(2) UNSIGNED default '50';
) ENGINE=MyISAM; ) ENGINE=MyISAM;
CREATE TABLE vicidial_lists ( CREATE TABLE vicidial_lists (
@@ -5875,4 +5876,4 @@ INSERT INTO `wallboard_reports` VALUES ('AGENTS_AND_QUEUES','Agents and Queues',
UPDATE system_settings set vdc_agent_api_active='1'; UPDATE system_settings set vdc_agent_api_active='1';
UPDATE system_settings SET db_schema_version='1734',db_schema_update_date=NOW(),reload_timestamp=NOW(); UPDATE system_settings SET db_schema_version='1735',db_schema_update_date=NOW(),reload_timestamp=NOW();
+7 -1
View File
@@ -1368,7 +1368,7 @@ UPDATE system_settings SET db_schema_version='1613',db_schema_update_date=NOW()
ALTER TABLE system_settings ADD allow_shared_dial ENUM('0','1','2','3','4','5','6') default '0'; ALTER TABLE system_settings ADD allow_shared_dial ENUM('0','1','2','3','4','5','6') default '0';
ALTER TABLE vicidial_campaigns ADD shared_dial_rank TINYINT(3) default '99'; ALTER TABLE vicidial_campaigns ADD shared_dial_rank TINYINT(3) default '99';
ALTER TABLE vicidial_campaigns MODIFY dial_method ENUM('MANUAL','RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','INBOUND_MAN','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE') default 'MANUAL'; ALTER TABLE vicidial_campaigns MODIFY dial_method ENUM('MANUAL','RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','INBOUND_MAN','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX') default 'MANUAL';
ALTER TABLE vicidial_live_agents ADD dial_campaign_id VARCHAR(8) default ''; ALTER TABLE vicidial_live_agents ADD dial_campaign_id VARCHAR(8) default '';
@@ -3044,3 +3044,9 @@ UPDATE system_settings SET db_schema_version='1733',db_schema_update_date=NOW()
ALTER TABLE vicidial_inbound_dids ADD alter_cid_name VARCHAR(40) default 'DISABLED'; ALTER TABLE vicidial_inbound_dids ADD alter_cid_name VARCHAR(40) default 'DISABLED';
UPDATE system_settings SET db_schema_version='1734',db_schema_update_date=NOW() where db_schema_version < 1734; UPDATE system_settings SET db_schema_version='1734',db_schema_update_date=NOW() where db_schema_version < 1734;
ALTER TABLE vicidial_campaigns MODIFY dial_method ENUM('MANUAL','RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','INBOUND_MAN','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX') default 'MANUAL';
ALTER TABLE vicidial_campaigns ADD adaptive_percentmax_percentage TINYINT(2) UNSIGNED default '50';
UPDATE system_settings SET db_schema_version='1735',db_schema_update_date=NOW() where db_schema_version < 1735;
+8 -1
View File
@@ -58,13 +58,15 @@
# 210615-1032 - Default security fixes, CVE-2021-28854 # 210615-1032 - Default security fixes, CVE-2021-28854
# 220921-1204 - Added more failed login logging in user_authorization function # 220921-1204 - Added more failed login logging in user_authorization function
# 230518-1111 - Added in-group and campaign custom fields 1-5, for script/webform/dispo-call-url use # 230518-1111 - Added in-group and campaign custom fields 1-5, for script/webform/dispo-call-url use
# 251205-1742 - Fix for undefined variable issue
# #
if (!isset($mel)) {$mel=0;}
# $mysql_queries = 28 # $mysql_queries = 28
##### BEGIN validate user login credentials, check for failed lock out ##### ##### BEGIN validate user login credentials, check for failed lock out #####
function user_authorization($user,$pass,$user_option,$user_update,$bcrypt,$return_hash,$api_call,$source) function user_authorization($user,$pass,$user_option,$user_update,$bcrypt,$return_hash,$api_call,$source)
{ {
global $mel;
require("dbconnect_mysqli.php"); require("dbconnect_mysqli.php");
############################################# #############################################
@@ -344,6 +346,7 @@ function user_authorization($user,$pass,$user_option,$user_update,$bcrypt,$retur
##### BEGIN custom_list_fields_values - gather values for display of custom list fields for a lead ##### ##### BEGIN custom_list_fields_values - gather values for display of custom list fields for a lead #####
function custom_list_fields_values($lead_id,$list_id,$uniqueid,$user,$DB,$call_id,$did_id,$did_extension,$did_pattern,$did_description,$dialed_number,$dialed_label,$only_field,$source_field,$source_field_value) function custom_list_fields_values($lead_id,$list_id,$uniqueid,$user,$DB,$call_id,$did_id,$did_extension,$did_pattern,$did_description,$dialed_number,$dialed_label,$only_field,$source_field,$source_field_value)
{ {
global $mel;
$STARTtime = date("U"); $STARTtime = date("U");
$TODAY = date("Y-m-d"); $TODAY = date("Y-m-d");
$NOW_TIME = date("Y-m-d H:i:s"); $NOW_TIME = date("Y-m-d H:i:s");
@@ -1582,6 +1585,7 @@ function custom_list_fields_values($lead_id,$list_id,$uniqueid,$user,$DB,$call_i
function lookup_gmt($phone_code,$USarea,$state,$LOCAL_GMT_OFF_STD,$Shour,$Smin,$Ssec,$Smon,$Smday,$Syear,$postalgmt,$postal_code) function lookup_gmt($phone_code,$USarea,$state,$LOCAL_GMT_OFF_STD,$Shour,$Smin,$Ssec,$Smon,$Smday,$Syear,$postalgmt,$postal_code)
{ {
global $mel;
require("dbconnect_mysqli.php"); require("dbconnect_mysqli.php");
$postalgmt_found=0; $postalgmt_found=0;
@@ -2343,6 +2347,7 @@ function lookup_gmt($phone_code,$USarea,$state,$LOCAL_GMT_OFF_STD,$Shour,$Smin,$
##### DETERMINE IF LEAD IS DIALABLE ##### ##### DETERMINE IF LEAD IS DIALABLE #####
function dialable_gmt($DB,$link,$local_call_time,$gmt_offset,$state) function dialable_gmt($DB,$link,$local_call_time,$gmt_offset,$state)
{ {
global $mel;
require("dbconnect_mysqli.php"); require("dbconnect_mysqli.php");
$dialable=0; $dialable=0;
@@ -2709,6 +2714,7 @@ function dialable_gmt($DB,$link,$local_call_time,$gmt_offset,$state)
##### AJAX process logging ##### ##### AJAX process logging #####
function vicidial_ajax_log($NOW_TIME,$startMS,$link,$ACTION,$php_script,$user,$stage,$lead_id,$session_name,$stmt) function vicidial_ajax_log($NOW_TIME,$startMS,$link,$ACTION,$php_script,$user,$stage,$lead_id,$session_name,$stmt)
{ {
global $mel;
$endMS = microtime(); $endMS = microtime();
$startMSary = explode(" ",$startMS); $startMSary = explode(" ",$startMS);
$endMSary = explode(" ",$endMS); $endMSary = explode(" ",$endMS);
@@ -2741,6 +2747,7 @@ function vicidial_ajax_log($NOW_TIME,$startMS,$link,$ACTION,$php_script,$user,$s
##### MySQL Error Logging ##### ##### MySQL Error Logging #####
function mysql_error_logging($NOW_TIME,$link,$mel,$stmt,$query_id,$user,$server_ip,$session_name,$one_mysql_log) function mysql_error_logging($NOW_TIME,$link,$mel,$stmt,$query_id,$user,$server_ip,$session_name,$one_mysql_log)
{ {
global $mel;
$NOW_TIME = date("Y-m-d H:i:s"); $NOW_TIME = date("Y-m-d H:i:s");
# mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00001',$user,$server_ip,$session_name,$one_mysql_log); # mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00001',$user,$server_ip,$session_name,$one_mysql_log);
$errno=''; $error=''; $errno=''; $error='';
@@ -1,7 +1,7 @@
<?php <?php
# AST_timeonVDADallSUMMARY.php # AST_timeonVDADallSUMMARY.php
# #
# Copyright (C) 2022 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2 # Copyright (C) 2025 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2
# #
# Summary for all campaigns live real-time stats for the VICIDIAL Auto-Dialer all servers # Summary for all campaigns live real-time stats for the VICIDIAL Auto-Dialer all servers
# #
@@ -32,6 +32,7 @@
# 170409-1534 - Added IP List validation code # 170409-1534 - Added IP List validation code
# 190927-1300 - Fixed PHP7 array issue # 190927-1300 - Fixed PHP7 array issue
# 220301-2044 - Added allow_web_debug system setting # 220301-2044 - Added allow_web_debug system setting
# 251205-1931 - Added ADAPT_PERCENTMAX
# #
require("dbconnect_mysqli.php"); require("dbconnect_mysqli.php");
@@ -213,7 +214,7 @@ if ( (!preg_match('/\-ALL/i', $LOGallowed_campaigns)) )
} }
$campaign_typeSQL=''; $campaign_typeSQL='';
if ($types == 'AUTO-DIAL ONLY') {$campaign_typeSQL="and dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE')";} if ($types == 'AUTO-DIAL ONLY') {$campaign_typeSQL="and dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX')";}
if ($types == 'MANUAL ONLY') {$campaign_typeSQL="and dial_method IN('MANUAL','INBOUND_MAN')";} if ($types == 'MANUAL ONLY') {$campaign_typeSQL="and dial_method IN('MANUAL','INBOUND_MAN')";}
if ($types == 'INBOUND ONLY') {$campaign_typeSQL="and campaign_allow_inbound='Y'";} if ($types == 'INBOUND ONLY') {$campaign_typeSQL="and campaign_allow_inbound='Y'";}
@@ -1,7 +1,7 @@
<?php <?php
# AST_timeonVDADallSUMMARY_mobile.php # AST_timeonVDADallSUMMARY_mobile.php
# #
# Copyright (C) 2024 Matt Florell <vicidial@gmail.com>, Joe Johnson <freewermadmin@gmail.com> LICENSE: AGPLv2 # Copyright (C) 2025 Matt Florell <vicidial@gmail.com>, Joe Johnson <freewermadmin@gmail.com> LICENSE: AGPLv2
# #
# Mobile version of summary report for all campaigns live real-time stats for the VICIDIAL Auto-Dialer all servers # Mobile version of summary report for all campaigns live real-time stats for the VICIDIAL Auto-Dialer all servers
# #
@@ -13,6 +13,7 @@
# 200414-2000 - Minor display modifications, auto-selecting refresh rate onload # 200414-2000 - Minor display modifications, auto-selecting refresh rate onload
# 220301-2036 - Added allow_web_debug system setting # 220301-2036 - Added allow_web_debug system setting
# 240801-1130 - Code updates for PHP8 compatibility # 240801-1130 - Code updates for PHP8 compatibility
# 251205-1932 - Added ADAPT_PERCENTMAX
# #
require("dbconnect_mysqli.php"); require("dbconnect_mysqli.php");
@@ -211,7 +212,7 @@ $campaign_typeSQL='';
if (count($types)<2) if (count($types)<2)
{ {
$types = preg_replace('/[^- \_0-9\p{L}]/u', '', $types); $types = preg_replace('/[^- \_0-9\p{L}]/u', '', $types);
if ($types == 'AUTO-DIAL ONLY') {$campaign_typeSQL="and dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE')";} if ($types == 'AUTO-DIAL ONLY') {$campaign_typeSQL="and dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX')";}
if ($types == 'MANUAL ONLY') {$campaign_typeSQL="and dial_method IN('MANUAL','INBOUND_MAN')";} if ($types == 'MANUAL ONLY') {$campaign_typeSQL="and dial_method IN('MANUAL','INBOUND_MAN')";}
if ($types == 'INBOUND ONLY') {$campaign_typeSQL="and campaign_allow_inbound='Y'";} if ($types == 'INBOUND ONLY') {$campaign_typeSQL="and campaign_allow_inbound='Y'";}
} }
@@ -221,7 +222,7 @@ else
{ {
$types = preg_replace('/[^- \_0-9\p{L}]/u', '', $types); $types = preg_replace('/[^- \_0-9\p{L}]/u', '', $types);
$campaign_typeSQL='and ('; $campaign_typeSQL='and (';
if (in_array('AUTO-DIAL ONLY', $types)) {$campaign_typeSQL="dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE') or ";} # unset($types['AUTO-DIAL ONLY']); if (in_array('AUTO-DIAL ONLY', $types)) {$campaign_typeSQL="dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX') or ";} # unset($types['AUTO-DIAL ONLY']);
if (in_array('MANUAL ONLY', $types)) {$campaign_typeSQL="dial_method IN('MANUAL','INBOUND_MAN') or ";} # unset($types['MANUAL ONLY']); if (in_array('MANUAL ONLY', $types)) {$campaign_typeSQL="dial_method IN('MANUAL','INBOUND_MAN') or ";} # unset($types['MANUAL ONLY']);
if (in_array('INBOUND ONLY', $types)) {$campaign_typeSQL="campaign_allow_inbound='Y' or ";} # unset($types['INBOUND ONLY']); if (in_array('INBOUND ONLY', $types)) {$campaign_typeSQL="campaign_allow_inbound='Y' or ";} # unset($types['INBOUND ONLY']);
$campaign_typeSQL='campaign_id in ('.implode("', '", $types).')'; $campaign_typeSQL='campaign_id in ('.implode("', '", $types).')';
File diff suppressed because one or more lines are too long
@@ -1,7 +1,7 @@
<?php <?php
# campaign_summary_mobile_report.php # campaign_summary_mobile_report.php
# #
# Copyright (C) 2024 Matt Florell <vicidial@gmail.com>, Joe Johnson <freewermadmin@gmail.com> LICENSE: AGPLv2 # Copyright (C) 2025 Matt Florell <vicidial@gmail.com>, Joe Johnson <freewermadmin@gmail.com> LICENSE: AGPLv2
# #
# Back-end PHP script that generates text output to be interpreted by AST_timeonVDADallSUMMARY_mobile.php # Back-end PHP script that generates text output to be interpreted by AST_timeonVDADallSUMMARY_mobile.php
# #
@@ -12,6 +12,7 @@
# 181212-2329 - Initial build # 181212-2329 - Initial build
# 220301-1015 - Added allow_web_debug system setting # 220301-1015 - Added allow_web_debug system setting
# 240801-1130 - Code updates for PHP8 compatibility # 240801-1130 - Code updates for PHP8 compatibility
# 251205-1929 - Added ADAPT_PERCENTMAX option
# #
require("dbconnect_mysqli.php"); require("dbconnect_mysqli.php");
@@ -216,7 +217,7 @@ $campaign_typeSQL='';
if (count($types)<2) { if (count($types)<2) {
$types = preg_replace('/[^- \_0-9\p{L}]/u', '', $types); $types = preg_replace('/[^- \_0-9\p{L}]/u', '', $types);
if (in_array('LIST ALL CAMPAIGNS', $types)) {$campaign_typeSQL="";} if (in_array('LIST ALL CAMPAIGNS', $types)) {$campaign_typeSQL="";}
else if (in_array('AUTO-DIAL ONLY', $types)) {$campaign_typeSQL="and dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE')";} else if (in_array('AUTO-DIAL ONLY', $types)) {$campaign_typeSQL="and dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX')";}
else if (in_array('MANUAL ONLY', $types)) {$campaign_typeSQL="and dial_method IN('MANUAL','INBOUND_MAN')";} else if (in_array('MANUAL ONLY', $types)) {$campaign_typeSQL="and dial_method IN('MANUAL','INBOUND_MAN')";}
else if (in_array('INBOUND ONLY', $types)) {$campaign_typeSQL="and campaign_allow_inbound='Y'";} else if (in_array('INBOUND ONLY', $types)) {$campaign_typeSQL="and campaign_allow_inbound='Y'";}
else if ($typesSQL) {$campaign_typeSQL="and campaign_id IN(".$typesSQL.")";} else if ($typesSQL) {$campaign_typeSQL="and campaign_id IN(".$typesSQL.")";}
@@ -225,7 +226,7 @@ if (count($types)<2) {
$campaign_typeSQL='and ('; $campaign_typeSQL='and (';
if (in_array('AUTO-DIAL ONLY', $types)) if (in_array('AUTO-DIAL ONLY', $types))
{ {
$campaign_typeSQL.="dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE') or "; # $campaign_typeSQL.="dial_method IN('RATIO','ADAPT_HARD_LIMIT','ADAPT_TAPERED','ADAPT_AVERAGE','ADAPT_PERCENTMAX','SHARED_RATIO','SHARED_ADAPT_HARD_LIMIT','SHARED_ADAPT_TAPERED','SHARED_ADAPT_AVERAGE','SHARED_ADAPT_PERCENTMAX') or "; #
$index = array_search('AUTO-DIAL ONLY', $types); $index = array_search('AUTO-DIAL ONLY', $types);
unset($types[$index]); unset($types[$index]);
} }
@@ -1,4 +1,4 @@
# version: 20251203232501 # version: 20251205193301
users-user User ID <QXZ>This field is where you put the users ID number, can be up to 20 digits in length, Must be at least 2 characters in length. We strongly recommend not reusing user accounts for different users, for reporting accuracy. To disable a user account, set the Active option to -N-.</QXZ> users-user User ID <QXZ>This field is where you put the users ID number, can be up to 20 digits in length, Must be at least 2 characters in length. We strongly recommend not reusing user accounts for different users, for reporting accuracy. To disable a user account, set the Active option to -N-.</QXZ>
users-pass Password <QXZ>This field is where you put the users password. Must be at least 2 characters in length, unless the User Password Minimum Length system setting is enabled, which will require a longer password. Only letters and numbers are allowed in user passwords. A medium strength user password will be at least 10 characters in length, and a strong user password will be at least 20 characters in length and have letters as well as at least one number. It is recommended that you use a longer password if possible, stringing together several unrelated words with no spaces, and a number somewhere in the string. The maximum size of a password is 100 characters.</QXZ> users-pass Password <QXZ>This field is where you put the users password. Must be at least 2 characters in length, unless the User Password Minimum Length system setting is enabled, which will require a longer password. Only letters and numbers are allowed in user passwords. A medium strength user password will be at least 10 characters in length, and a strong user password will be at least 20 characters in length and have letters as well as at least one number. It is recommended that you use a longer password if possible, stringing together several unrelated words with no spaces, and a number somewhere in the string. The maximum size of a password is 100 characters.</QXZ>
users-force_change_password Force Change Password <QXZ>If this option is set to Y then the user will be prompted to change their password the next time they log in to the administration webpage or the agent screen. Default is N.</QXZ> users-force_change_password Force Change Password <QXZ>If this option is set to Y then the user will be prompted to change their password the next time they log in to the administration webpage or the agent screen. Default is N.</QXZ>
@@ -169,7 +169,7 @@ campaigns-hopper_drop_run_trigger Hopper Drop-Run Trigger <QXZ>This setting, if
campaigns-drop_lockout_time Drop Lockout Time <QXZ>This is a number of hours that DROP abandon calls will be prevented from being dialed, to disable set to 0. This setting is very useful in countries like the UK where there are regulations preventing the attempted calling of customers within 72 hours of an Abandon, or DROP. Default is 0.</QXZ> campaigns-drop_lockout_time Drop Lockout Time <QXZ>This is a number of hours that DROP abandon calls will be prevented from being dialed, to disable set to 0. This setting is very useful in countries like the UK where there are regulations preventing the attempted calling of customers within 72 hours of an Abandon, or DROP. Default is 0.</QXZ>
campaigns-force_reset_hopper Force Reset of Hopper <QXZ>This allows you to wipe out the hopper contents upon form submission. It should be filled again when the VDhopper script runs.</QXZ> campaigns-force_reset_hopper Force Reset of Hopper <QXZ>This allows you to wipe out the hopper contents upon form submission. It should be filled again when the VDhopper script runs.</QXZ>
campaigns-hopper_hold_inserts Hopper Hold Inserts <QXZ>If enabled, this will insert leads into the hopper as a RHOLD status, so they can be activated by an outside process or utility. The AUTONEXT option is also an enabled option, but in the HCI Screen, the user will only have to click once for each call instead of twice. Default is DISABLED.</QXZ> campaigns-hopper_hold_inserts Hopper Hold Inserts <QXZ>If enabled, this will insert leads into the hopper as a RHOLD status, so they can be activated by an outside process or utility. The AUTONEXT option is also an enabled option, but in the HCI Screen, the user will only have to click once for each call instead of twice. Default is DISABLED.</QXZ>
campaigns-dial_method Dial Method <QXZ>This field is the way to define how dialing is to take place. If MANUAL then the auto_dial_level will be locked at 0 unless Dial Method is changed. If RATIO then the normal dialing a number of lines for Active agents. ADAPT_HARD_LIMIT will dial predictively up to the dropped percentage and then not allow aggressive dialing once the drop limit is reached until the percentage goes down again. ADAPT_TAPERED allows for running over the dropped percentage in the beginning of the shift -as defined by Latest Server Time set for campaign- and gets more strict as the shift goes on, for example, if there are 10 hours or more left in the shift, the TAPERED feature will not affect the adaptive dial level at all, as the number of hours left in the shift drops below 10 hours and gets closer to 0, the dial level will be dropped closer and closer to 1.0 as time goes on. ADAPT_AVERAGE tries to maintain an average or the dropped percentage not imposing hard limits as aggressively as the other two methods. You cannot change the Auto Dial Level if you are in any of the ADAPT dial methods. Only the Dialer can change the dial level when in predictive dialing mode. INBOUND_MAN allows the agent to place manual dial calls from a campaign list while being able to take inbound calls between manual dial calls.</QXZ> campaigns-dial_method Dial Method <QXZ>This field is the way to define how dialing is to take place. If MANUAL then the auto_dial_level will be locked at 0 unless Dial Method is changed. If RATIO then the normal dialing a number of lines for Active agents. ADAPT_HARD_LIMIT will dial predictively up to the dropped percentage and then not allow aggressive dialing once the drop limit is reached until the percentage goes down again. ADAPT_TAPERED allows for running over the dropped percentage in the beginning of the shift -as defined by Latest Server Time set for campaign- and gets more strict as the shift goes on, for example, if there are 10 hours or more left in the shift, the TAPERED feature will not affect the adaptive dial level at all, as the number of hours left in the shift drops below 10 hours and gets closer to 0, the dial level will be dropped closer and closer to 1.0 as time goes on. ADAPT_AVERAGE tries to maintain an average or the dropped percentage not imposing hard limits as aggressively as the other two methods. ADAPT_PERCENTMAX will use the Adapt Percent-Max Percentage and the Maximum Adapt Dial Level settings to calculate what it should set the Dial Level to if the dropped percentage limit is reached, and if the calculated value is greater than the current Dial Level, then it won't be changed at that time. You cannot change the Auto Dial Level if you are in any of the ADAPT dial methods. Only the Dialer can change the dial level when in predictive dialing mode. INBOUND_MAN allows the agent to place manual dial calls from a campaign list while being able to take inbound calls between manual dial calls.</QXZ>
campaigns-auto_dial_level Auto Dial Level <QXZ>This is where you set how many lines the system should use per active agent. zero 0 means auto dialing is off and the agents will click to dial each number. Otherwise the system will keep dialing lines equal to active agents multiplied by the dial level to arrive at how many lines this campaign on each server should allow. The ADAPT OVERRIDE checkbox allows you to force a new dial level even though the dial method is in an ADAPT mode. This is useful if there is a dramatic shift in the quality of leads and you want to drastically change the dial_level manually. Note: With the INBOUND_MAN Dial Method, this setting needs to be set to 1.0 so that inbound calls can be received by agents, but even with this set above 0, there will be no auto-dial calls placed from the campaign.</QXZ> campaigns-auto_dial_level Auto Dial Level <QXZ>This is where you set how many lines the system should use per active agent. zero 0 means auto dialing is off and the agents will click to dial each number. Otherwise the system will keep dialing lines equal to active agents multiplied by the dial level to arrive at how many lines this campaign on each server should allow. The ADAPT OVERRIDE checkbox allows you to force a new dial level even though the dial method is in an ADAPT mode. This is useful if there is a dramatic shift in the quality of leads and you want to drastically change the dial_level manually. Note: With the INBOUND_MAN Dial Method, this setting needs to be set to 1.0 so that inbound calls can be received by agents, but even with this set above 0, there will be no auto-dial calls placed from the campaign.</QXZ>
campaigns-dial_level_threshold Auto Dial Level Threshold <QXZ>This setting only works with an ADAPT or RATIO Dial Method, and it must be set to something other than DISABLED and the number of agents setting must be above 0. This feature allows you to set a minimum number agents that predictive algorithm will work at. If the number of agents falls below the number that you have set, then the dial level will go to 1.0 until more agents log in or go into the selected state. LOGGED-IN_AGENTS will count all agents logged into the campaign, NON-PAUSED_AGENTS will only count agents that are waiting or talking, and WAITING_AGENTS will only count agents that are waiting for a call. Default is DISABLED.</QXZ> campaigns-dial_level_threshold Auto Dial Level Threshold <QXZ>This setting only works with an ADAPT or RATIO Dial Method, and it must be set to something other than DISABLED and the number of agents setting must be above 0. This feature allows you to set a minimum number agents that predictive algorithm will work at. If the number of agents falls below the number that you have set, then the dial level will go to 1.0 until more agents log in or go into the selected state. LOGGED-IN_AGENTS will count all agents logged into the campaign, NON-PAUSED_AGENTS will only count agents that are waiting or talking, and WAITING_AGENTS will only count agents that are waiting for a call. Default is DISABLED.</QXZ>
campaigns-available_only_ratio_tally Available Only Tally <QXZ>This field if set to Y will leave out INCALL and QUEUE status agents when calculating the number of calls to dial when not in MANUAL dial mode. Default is N.</QXZ> campaigns-available_only_ratio_tally Available Only Tally <QXZ>This field if set to Y will leave out INCALL and QUEUE status agents when calculating the number of calls to dial when not in MANUAL dial mode. Default is N.</QXZ>
@@ -178,6 +178,7 @@ campaigns-incall_tally_threshold_seconds Agent In-Call Tally Seconds Threshold <
campaigns-adaptive_dropped_percentage Drop Percentage Limit <QXZ>This field is where you set the limit of the percentage of dropped calls you would like while using an adaptive-predictive dial method, not MANUAL or RATIO.</QXZ> campaigns-adaptive_dropped_percentage Drop Percentage Limit <QXZ>This field is where you set the limit of the percentage of dropped calls you would like while using an adaptive-predictive dial method, not MANUAL or RATIO.</QXZ>
campaigns-adaptive_maximum_level Maximum Adapt Dial Level <QXZ>This field is where you set the limit of the limit to the number of lines you would like dialed per agent while using an adaptive-predictive dial method, not MANUAL or RATIO. This number can be higher than the Auto Dial Level if your hardware will support it. Value must be a positive number greater than one and can have decimal places Default 3.0.</QXZ> campaigns-adaptive_maximum_level Maximum Adapt Dial Level <QXZ>This field is where you set the limit of the limit to the number of lines you would like dialed per agent while using an adaptive-predictive dial method, not MANUAL or RATIO. This number can be higher than the Auto Dial Level if your hardware will support it. Value must be a positive number greater than one and can have decimal places Default 3.0.</QXZ>
campaigns-adaptive_latest_server_time Latest Server Time <QXZ>This field is only used by the ADAPT_TAPERED dial method. You should enter in the hour and minute that you will stop calling on this campaign, 2100 would mean that you will stop dialing this campaign at 9PM server time. This allows the Tapered algorithm to decide how aggressively to dial by how long you have until you will be finished calling.</QXZ> campaigns-adaptive_latest_server_time Latest Server Time <QXZ>This field is only used by the ADAPT_TAPERED dial method. You should enter in the hour and minute that you will stop calling on this campaign, 2100 would mean that you will stop dialing this campaign at 9PM server time. This allows the Tapered algorithm to decide how aggressively to dial by how long you have until you will be finished calling.</QXZ>
campaigns-adaptive_percentmax_percentage Adapt Percent-Max Percentage <QXZ>If the ADAPT_PERCENTMAX dial method is used, then this is the option where you can set the percentage of the Maximum Adapt Dial Level that will be used if the Drop Percentage Limit is reached. Default is 50.</QXZ>
campaigns-adaptive_intensity Adapt Intensity Modifier <QXZ>This field is used to adjust the predictive intensity either higher or lower. The higher a positive number you select, the greater the dialer will increase the call pacing when it goes up and the slower the dialer will decrease the call pacing when it goes down. The lower the negative number you select here, the slower the dialer will increase the call pacing and the faster the dialer will lower the call pacing when it goes down. Default is 0. This field is not used by the MANUAL or RATIO dial methods.</QXZ> campaigns-adaptive_intensity Adapt Intensity Modifier <QXZ>This field is used to adjust the predictive intensity either higher or lower. The higher a positive number you select, the greater the dialer will increase the call pacing when it goes up and the slower the dialer will decrease the call pacing when it goes down. The lower the negative number you select here, the slower the dialer will increase the call pacing and the faster the dialer will lower the call pacing when it goes down. Default is 0. This field is not used by the MANUAL or RATIO dial methods.</QXZ>
campaigns-adaptive_dl_diff_target Dial Level Difference Target <QXZ>This field is used to define whether you want to target having a specific number of agents waiting for calls or calls waiting for agents. For example if you would always like to have on average one agent free to take calls immediately you would set this to -1, if you would like to target always having one call on hold waiting for an agent you would set this to 1. Default is 0. This field is not used by the MANUAL or INBOUND_MAN dial methods.</QXZ> campaigns-adaptive_dl_diff_target Dial Level Difference Target <QXZ>This field is used to define whether you want to target having a specific number of agents waiting for calls or calls waiting for agents. For example if you would always like to have on average one agent free to take calls immediately you would set this to -1, if you would like to target always having one call on hold waiting for an agent you would set this to 1. Default is 0. This field is not used by the MANUAL or INBOUND_MAN dial methods.</QXZ>
campaigns-dl_diff_target_method Dial Level Difference Target Method <QXZ>This option allows you to define whether the dial level difference target setting is applied only to the calculation of the dial level or also to the actual dialing on each dialing server. If you are running a small campaign with agents logged in on many servers you may want to use the ADAPT_CALC_ONLY option, because the CALLS_PLACED option may result in fewer calls being placed than desired. This option is only active if Dial Level Difference Target is set to something other than 0. Default is ADAPT_CALC_ONLY.</QXZ> campaigns-dl_diff_target_method Dial Level Difference Target Method <QXZ>This option allows you to define whether the dial level difference target setting is applied only to the calculation of the dial level or also to the actual dialing on each dialing server. If you are running a small campaign with agents logged in on many servers you may want to use the ADAPT_CALC_ONLY option, because the CALLS_PLACED option may result in fewer calls being placed than desired. This option is only active if Dial Level Difference Target is set to something other than 0. Default is ADAPT_CALC_ONLY.</QXZ>
+3 -2
View File
@@ -225,10 +225,11 @@
# 250516-1047 - Changed ksort to uksort so array sorting by key is alphabetic, case-INsensitive # 250516-1047 - Changed ksort to uksort so array sorting by key is alphabetic, case-INsensitive
# 250620-1007 - Added apinewlead_url requests for add_lead when new leads are inserted # 250620-1007 - Added apinewlead_url requests for add_lead when new leads are inserted
# 250720-1841 - Added hopper_bulk_insert function # 250720-1841 - Added hopper_bulk_insert function
# 251205-1456 - Added ADAPT_PERCENTMAX dial_method
# #
$version = '2.14-202'; $version = '2.14-202';
$build = '250720-1841'; $build = '251205-1456';
$php_script='non_agent_api.php'; $php_script='non_agent_api.php';
$api_url_log = 0; $api_url_log = 0;
$camp_lead_order_random=1; $camp_lead_order_random=1;
@@ -8918,7 +8919,7 @@ if ($function == 'update_campaign')
} }
if (strlen($dial_method) > 0) if (strlen($dial_method) > 0)
{ {
if (preg_match("/^MANUAL$|^RATIO$|^INBOUND_MAN$|^ADAPT_AVERAGE$|^ADAPT_HARD_LIMIT$|^ADAPT_TAPERED$/",$dial_method)) if (preg_match("/^MANUAL$|^RATIO$|^INBOUND_MAN$|^ADAPT_AVERAGE$|^ADAPT_HARD_LIMIT$|^ADAPT_TAPERED$|^ADAPT_PERCENTMAX$|^SHARED_RATIO$|^SHARED_ADAPT_AVERAGE$|^SHARED_ADAPT_HARD_LIMIT$|^SHARED_ADAPT_TAPERED$|^SHARED_ADAPT_PERCENTMAX$/",$dial_method))
{$dialmethodSQL = " ,dial_method='$dial_method'";} {$dialmethodSQL = " ,dial_method='$dial_method'";}
else else
{ {