fixed bug in export lead report

removed phones select from auth process in agent directory
added indexes to vicidial_live_agents

git-svn-id: svn://192.168.202.10@2242 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2015-01-08 22:08:04 +00:00
parent dffc7911ef
commit d7f6f3df56
6 changed files with 30 additions and 20 deletions
+1 -1
View File
@@ -112,7 +112,7 @@ OTHER CHANGES:
20. Added new user option to allow administrative users to search for leads 20. Added new user option to allow administrative users to search for leads
systemwide even in lists belonging to campaigns that the user's User systemwide even in lists belonging to campaigns that the user's User
Group settings don't allow them to veiw Group settings don't allow them to view
@@ -26,7 +26,7 @@ For our clients that believe preview dialing, or click-to-dial list dialing, is
UPDATE vicidial_campaigns SET auto_dial_level='1' where auto_dial_level NOT IN('0','1','1.0'); UPDATE vicidial_campaigns SET auto_dial_level='1' where auto_dial_level NOT IN('0','1','1.0');
ALTER TABLE vicidial_campaigns MODIFY auto_dial_level ENUM('0','1','1.0') default '0' NOT NULL; ALTER TABLE vicidial_campaigns MODIFY auto_dial_level ENUM('0','1','1.0') default '0' NOT NULL;
quit quit
<you can also optionally remove the adaptive eial methods from the web interface> <you can also optionally remove the adaptive dial methods from the web interface>
find /srv/www/htdocs/vicidial/ -type f -exec sed -i 's/ADAPT_HARD_LIMIT/MANUAL/g' {} + find /srv/www/htdocs/vicidial/ -type f -exec sed -i 's/ADAPT_HARD_LIMIT/MANUAL/g' {} +
find /srv/www/htdocs/vicidial/ -type f -exec sed -i 's/ADAPT_AVERAGE/MANUAL/g' {} + find /srv/www/htdocs/vicidial/ -type f -exec sed -i 's/ADAPT_AVERAGE/MANUAL/g' {} +
find /srv/www/htdocs/vicidial/ -type f -exec sed -i 's/ADAPT_TAPERED/MANUAL/g' {} + find /srv/www/htdocs/vicidial/ -type f -exec sed -i 's/ADAPT_TAPERED/MANUAL/g' {} +
@@ -3252,6 +3252,9 @@ CREATE INDEX comment_a on live_inbound_log (comment_a);
CREATE UNIQUE INDEX vicidial_campaign_statuses_key on vicidial_campaign_statuses(status, campaign_id); CREATE UNIQUE INDEX vicidial_campaign_statuses_key on vicidial_campaign_statuses(status, campaign_id);
CREATE INDEX vlecc on vicidial_log_extended (caller_code); CREATE INDEX vlecc on vicidial_log_extended (caller_code);
CREATE INDEX vlali on vicidial_live_agents (lead_id);
CREATE INDEX vlaus on vicidial_live_agents (user);
CREATE TABLE call_log_archive LIKE call_log; CREATE TABLE call_log_archive LIKE call_log;
CREATE TABLE vicidial_log_archive LIKE vicidial_log; CREATE TABLE vicidial_log_archive LIKE vicidial_log;
@@ -3360,4 +3363,4 @@ UPDATE vicidial_configuration set value='1766' where name='qc_database_version';
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='1397',db_schema_update_date=NOW(),reload_timestamp=NOW(); UPDATE system_settings SET db_schema_version='1398',db_schema_update_date=NOW(),reload_timestamp=NOW();
+5
View File
@@ -155,3 +155,8 @@ UPDATE system_settings SET db_schema_version='1396',db_schema_update_date=NOW()
ALTER TABLE vicidial_users ADD ignore_group_on_search ENUM('1','0') default '0'; ALTER TABLE vicidial_users ADD ignore_group_on_search ENUM('1','0') default '0';
UPDATE system_settings SET db_schema_version='1397',db_schema_update_date=NOW() where db_schema_version < 1397; UPDATE system_settings SET db_schema_version='1397',db_schema_update_date=NOW() where db_schema_version < 1397;
CREATE INDEX vlali on vicidial_live_agents (lead_id);
CREATE INDEX vlaus on vicidial_live_agents (user);
UPDATE system_settings SET db_schema_version='1398',db_schema_update_date=NOW() where db_schema_version < 1398;
+16 -15
View File
@@ -4,7 +4,7 @@
# #
# functions for agent scripts # functions for agent scripts
# #
# Copyright (C) 2014 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2 # Copyright (C) 2015 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2
# #
# #
# CHANGES: # CHANGES:
@@ -24,6 +24,7 @@
# 141118-0909 - Added options for up to 9 ordered variables within QXZ function output # 141118-0909 - Added options for up to 9 ordered variables within QXZ function output
# 141128-0846 - Code cleanup for QXZ functions # 141128-0846 - Code cleanup for QXZ functions
# 141216-1902 - Added MYSQL language method # 141216-1902 - Added MYSQL language method
# 150108-1647 - removed phones count as part of validation, can cause problems when there are many phones
# #
# $mysql_queries = 20 # $mysql_queries = 20
@@ -147,15 +148,15 @@ function user_authorization($user,$pass,$user_option,$user_update,$bcrypt,$retur
$aas_total = $row[0]; $aas_total = $row[0];
} }
$stmt = "SELECT count(*) FROM phones where active='Y';"; # $stmt = "SELECT count(*) FROM phones where active='Y';";
$rslt=mysql_to_mysqli($stmt, $link); # $rslt=mysql_to_mysqli($stmt, $link);
if ($DB) {echo "$stmt\n";} # if ($DB) {echo "$stmt\n";}
$ap_ct = mysqli_num_rows($rslt); # $ap_ct = mysqli_num_rows($rslt);
if ($ap_ct > 0) # if ($ap_ct > 0)
{ # {
$row=mysqli_fetch_row($rslt); # $row=mysqli_fetch_row($rslt);
$ap_total = $row[0]; # $ap_total = $row[0];
} # }
$stmt = "SELECT count(*) FROM vicidial_live_agents where user!='$user';"; $stmt = "SELECT count(*) FROM vicidial_live_agents where user!='$user';";
$rslt=mysql_to_mysqli($stmt, $link); $rslt=mysql_to_mysqli($stmt, $link);
@@ -191,11 +192,11 @@ function user_authorization($user,$pass,$user_option,$user_update,$bcrypt,$retur
$auth_key='ERRSERVERS'; $auth_key='ERRSERVERS';
$login_problem++; $login_problem++;
} }
if ($ap_total < 1) # if ($ap_total < 1)
{ # {
$auth_key='ERRPHONES'; # $auth_key='ERRPHONES';
$login_problem++; # $login_problem++;
} # }
if ( ($vla_total >= $vla_set) and ($vla_on > 0) ) if ( ($vla_total >= $vla_set) and ($vla_on > 0) )
{ {
$auth_key='ERRAGENTS'; $auth_key='ERRAGENTS';
@@ -5,7 +5,7 @@
# vicidial_log and/or vicidial_closer_log information by status, list_id and # vicidial_log and/or vicidial_closer_log information by status, list_id and
# date range. downloads to a flat text file that is tab delimited # date range. downloads to a flat text file that is tab delimited
# #
# Copyright (C) 2014 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2 # Copyright (C) 2015 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2
# #
# CHANGES # CHANGES
# #
@@ -19,6 +19,7 @@
# 140108-0710 - Added webserver and hostname to report logging # 140108-0710 - Added webserver and hostname to report logging
# 141114-0039 - Finalized adding QXZ translation to all admin files # 141114-0039 - Finalized adding QXZ translation to all admin files
# 141230-0951 - Added code for on-the-fly language translations display # 141230-0951 - Added code for on-the-fly language translations display
# 150108-1705 - Fixed issue with inbound and no outbound calls export
# #
$startMS = microtime(); $startMS = microtime();
@@ -423,7 +424,7 @@ if ($run_export > 0)
$rslt=mysql_to_mysqli($stmt, $link); $rslt=mysql_to_mysqli($stmt, $link);
if ($DB) {echo "$stmt\n";} if ($DB) {echo "$stmt\n";}
$outbound_to_print = mysqli_num_rows($rslt); $outbound_to_print = mysqli_num_rows($rslt);
if ($outbound_to_print < 1) if ( ($outbound_to_print < 1) and ($RUNgroup < 1) )
{ {
echo _QXZ("There are no outbound calls during this time period for these parameters")."\n"; echo _QXZ("There are no outbound calls during this time period for these parameters")."\n";
exit; exit;