From 9ed9bb265c5f3d95e6530b02261f6b0030beeee6 Mon Sep 17 00:00:00 2001 From: mattf Date: Fri, 4 Sep 2009 20:38:17 +0000 Subject: [PATCH] Added TIMEZONE lead order options for campaign dialing git-svn-id: svn://192.168.202.10@1217 3d104415-ff17-0410-8863-d5cf3c621b8a --- agc_2-X/trunk/UPGRADE | 1 + agc_2-X/trunk/bin/AST_VDhopper.pl | 3 ++ .../TO_BE_TRANSLATED_2.2.0.txt | 3 ++ agc_2-X/trunk/www/agc/vdc_db_query.php | 7 +++-- agc_2-X/trunk/www/vicidial/admin.php | 31 +++++++++++++++++-- 5 files changed, 41 insertions(+), 4 deletions(-) diff --git a/agc_2-X/trunk/UPGRADE b/agc_2-X/trunk/UPGRADE index 1daff82b..60de9788 100644 --- a/agc_2-X/trunk/UPGRADE +++ b/agc_2-X/trunk/UPGRADE @@ -218,6 +218,7 @@ NOTE: Upgrading from 1.1.12-3 to 2.0.1 is at the bottom 55. Added "Active Agent Server" option to servers to allow disabling of agent phone logins through ViciDial Agent Screen to a specific server +56. Added TIMEZONE UP and DOWN lead orders options for campaigns diff --git a/agc_2-X/trunk/bin/AST_VDhopper.pl b/agc_2-X/trunk/bin/AST_VDhopper.pl index 57ab09b7..e51cc515 100644 --- a/agc_2-X/trunk/bin/AST_VDhopper.pl +++ b/agc_2-X/trunk/bin/AST_VDhopper.pl @@ -57,6 +57,7 @@ # 90608-1201 - Added Drop Lockout Time Campaign setting option # 90723-0842 - Added no hopper dial option to clear hopper leads # 90809-0347 - Quick fix for null list_id loading when no active campaign lists +# 90904-1612 - Added timezone ordering # # constants @@ -1358,6 +1359,8 @@ foreach(@campaign_id) if ($lead_order[$i] =~ /^DOWN RANK/) {$order_stmt = 'order by rank, lead_id asc';} if ($lead_order[$i] =~ /^UP OWNER/) {$order_stmt = 'order by owner desc, lead_id asc';} if ($lead_order[$i] =~ /^DOWN OWNER/) {$order_stmt = 'order by owner, lead_id asc';} + if ($lead_order[$i] =~ /^UP TIMEZONE/) {$order_stmt = 'order by gmt_offset_now desc, lead_id asc';} + if ($lead_order[$i] =~ /^DOWN TIMEZONE/) {$order_stmt = 'order gmt_offset_now, lead_id asc';} if ($lead_order[$i] =~ / 2nd NEW$/) {$NEW_count = 2;} if ($lead_order[$i] =~ / 3rd NEW$/) {$NEW_count = 3;} if ($lead_order[$i] =~ / 4th NEW$/) {$NEW_count = 4;} 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 81468ec5..a3ec8880 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 @@ -295,6 +295,9 @@ MUSIC ON HOLD ENTRY NOT DELETED|| MUSIC ON HOLD ENTRY DELETION CONFIRMATION|| Click here to delete music on hold entry|| 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|| add-file: user_territories.php 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 cbdcf439..bf7af931 100644 --- a/agc_2-X/trunk/www/agc/vdc_db_query.php +++ b/agc_2-X/trunk/www/agc/vdc_db_query.php @@ -208,10 +208,11 @@ # 90722-1542 - Added no hopper dialing # 90729-0637 - Added DiaLableLeaDsCounT # 90808-0221 - Added last_state_change to vicidial_live_agents +# 90904-1622 - Added timezone sort options for no hopper dialing # -$version = '2.2.0-119'; -$build = '90808-0221'; +$version = '2.2.0-120'; +$build = '90904-1622'; $mel=1; # Mysql Error Log enabled = 1 $mysql_log_count=244; $one_mysql_log=0; @@ -1365,6 +1366,8 @@ if ($ACTION == 'manDiaLnextCaLL') if (eregi("DOWN RANK",$lead_order)){$order_stmt = 'order by rank, lead_id asc';} if (eregi("UP OWNER",$lead_order)){$order_stmt = 'order by owner desc, lead_id asc';} if (eregi("DOWN OWNER",$lead_order)){$order_stmt = 'order by owner, lead_id asc';} + if (eregi("UP TIMEZONE",$lead_order)){$order_stmt = 'order by gmt_offset_now desc, lead_id asc';} + if (eregi("DOWN TIMEZONE",$lead_order)){$order_stmt = 'order by gmt_offset_now, lead_id asc';} $stmt="UPDATE vicidial_list SET status='QUEUE',user='$user' where called_since_last_reset='N' and status IN($Dsql) and list_id IN($camp_lists) and ($all_gmtSQL) $DLTsql $fSQL $adooSQL $order_stmt LIMIT 1;"; if ($DB) {echo "$stmt\n";} diff --git a/agc_2-X/trunk/www/vicidial/admin.php b/agc_2-X/trunk/www/vicidial/admin.php index 990f9a74..3c1e284b 100644 --- a/agc_2-X/trunk/www/vicidial/admin.php +++ b/agc_2-X/trunk/www/vicidial/admin.php @@ -1938,7 +1938,7 @@ else # 90808-0300 - Added longest_wait_time option for agent call routing # 90827-1552 - Added agent_script_override option for lists # 90830-2217 - Added Music On Hold section -# 90904-1536 - Added moh chooser option +# 90904-1536 - Added moh chooser option, timezone list ordering # # 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 @@ -3322,6 +3322,8 @@ if ($SSoutbound_autodial_active > 0)
  - DOWN RANK: Starts with the lowest rank and works its way up
  - UP OWNER: Starts with owners beginning with Z and works its way down
  - DOWN OWNER: Starts with owners beginning with A and works its way up +
  - UP TIMEZONE: Starts with Eastern timezones and works West +
  - DOWN TIMEZONE: Starts with Western timezones and works East
@@ -7640,11 +7642,12 @@ if ($ADD=="2") { $user = 'AUTOGENERA'; } - if ( (strlen($user) < 2) or (strlen($pass) < 2) or (strlen($full_name) < 2) or ( (strlen($user) > 10) and (!ereg('AUTOGENERA',$user)) ) ) + if ( (strlen($user) < 2) or (strlen($pass) < 2) or (strlen($full_name) < 2) or (strlen($user_group) < 2) or ( (strlen($user) > 10) and (!ereg('AUTOGENERA',$user)) ) ) { echo "
USER NOT ADDED - Please go back and look at the data you entered\n"; echo "
user id must be between 2 and 10 characters long\n"; echo "
full name and password must be at least 2 characters long\n"; + echo "
you must select a user group\n"; } else { @@ -15559,6 +15562,8 @@ if ($ADD==31) + + @@ -15634,6 +15639,16 @@ if ($ADD==31) + + + + + + + + + + $NWB#vicidial_campaigns-lead_order$NWE\n"; echo "
List Mix: $NWB#vicidial_campaigns-lead_order$NWE\n"; echo "List Mix: