Added system settings option to remove campaign lock on agent only callbacks
git-svn-id: svn://192.168.202.10@1112 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
@@ -80,3 +80,10 @@ ALTER TABLE vicidial_inbound_dids ADD menu_id VARCHAR(50) default '';
|
||||
|
||||
UPDATE system_settings SET db_schema_version='1140';
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
ALTER TABLE system_settings ADD agentonly_callback_campaign_lock ENUM('0','1') default '1';
|
||||
|
||||
UPDATE system_settings SET db_schema_version='1141';
|
||||
|
||||
@@ -102,6 +102,8 @@ Show Call Menus||
|
||||
Add A New Call Menu||
|
||||
Copy Call Menu||
|
||||
To delete an Option, just set the Route to REMOVE and the option will be deleted when you click the SUBMIT button||
|
||||
Agent Only Callback Campaign Lock||
|
||||
This option defines whether AGENTONLY callbacks are locked to the campaign that the agent originally created them under. Setting this to 1 means that the agent can only dial them from the campaign they were set under, 0 means that the agent can access them no matter what campaign they are logged into. Default is 1||
|
||||
|
||||
|
||||
############################################################ CLIENT
|
||||
|
||||
@@ -198,10 +198,11 @@
|
||||
# 90327-1348 - Changed Vtiger status populate to use status name
|
||||
# 90408-0021 - Added API vtiger specific callback activity record ability
|
||||
# 90508-0726 - Changed to PHP long tags
|
||||
# 90511-0923 - Added agentonly_callback_campaign_lock option
|
||||
#
|
||||
|
||||
$version = '2.2.0-109';
|
||||
$build = '90508-0726';
|
||||
$version = '2.2.0-110';
|
||||
$build = '90511-0923';
|
||||
$mel=1; # Mysql Error Log enabled = 1
|
||||
$mysql_log_count=212;
|
||||
$one_mysql_log=0;
|
||||
@@ -388,7 +389,7 @@ $agents='@agents';
|
||||
|
||||
#############################################
|
||||
##### START SYSTEM_SETTINGS LOOKUP #####
|
||||
$stmt = "SELECT use_non_latin,timeclock_end_of_day FROM system_settings;";
|
||||
$stmt = "SELECT use_non_latin,timeclock_end_of_day,agentonly_callback_campaign_lock FROM system_settings;";
|
||||
$rslt=mysql_query($stmt, $link);
|
||||
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00001',$user,$server_ip,$session_name,$one_mysql_log);}
|
||||
if ($DB) {echo "$stmt\n";}
|
||||
@@ -397,8 +398,9 @@ $i=0;
|
||||
while ($i < $qm_conf_ct)
|
||||
{
|
||||
$row=mysql_fetch_row($rslt);
|
||||
$non_latin = $row[0];
|
||||
$timeclock_end_of_day = $row[1];
|
||||
$non_latin = $row[0];
|
||||
$timeclock_end_of_day = $row[1];
|
||||
$agentonly_callback_campaign_lock = $row[2];
|
||||
$i++;
|
||||
}
|
||||
##### END SETTINGS LOOKUP #####
|
||||
@@ -4318,7 +4320,11 @@ echo " Pause Code has been updated to $status for $agent_log_id\n";
|
||||
################################################################################
|
||||
if ($ACTION == 'CalLBacKLisT')
|
||||
{
|
||||
$stmt = "select callback_id,lead_id,campaign_id,status,entry_time,callback_time,comments from vicidial_callbacks where recipient='USERONLY' and user='$user' and campaign_id='$campaign' and status NOT IN('INACTIVE','DEAD') order by callback_time;";
|
||||
if ($agentonly_callback_campaign_lock > 0)
|
||||
{$campaignCBsql = "and campaign_id='$campaign'";}
|
||||
else
|
||||
{$campaignCBsql = '';}
|
||||
$stmt = "select callback_id,lead_id,campaign_id,status,entry_time,callback_time,comments from vicidial_callbacks where recipient='USERONLY' and user='$user' $campaignCBsql and status NOT IN('INACTIVE','DEAD') order by callback_time;";
|
||||
if ($DB) {echo "$stmt\n";}
|
||||
$rslt=mysql_query($stmt, $link);
|
||||
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00178',$user,$server_ip,$session_name,$one_mysql_log);}
|
||||
@@ -4358,7 +4364,11 @@ $loop_count=0;
|
||||
################################################################################
|
||||
if ($ACTION == 'CalLBacKCounT')
|
||||
{
|
||||
$stmt = "select count(*) from vicidial_callbacks where recipient='USERONLY' and user='$user' and campaign_id='$campaign' and status NOT IN('INACTIVE','DEAD');";
|
||||
if ($agentonly_callback_campaign_lock > 0)
|
||||
{$campaignCBsql = "and campaign_id='$campaign'";}
|
||||
else
|
||||
{$campaignCBsql = '';}
|
||||
$stmt = "select count(*) from vicidial_callbacks where recipient='USERONLY' and user='$user' $campaignCBsql and status NOT IN('INACTIVE','DEAD');";
|
||||
if ($DB) {echo "$stmt\n";}
|
||||
$rslt=mysql_query($stmt, $link);
|
||||
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00180',$user,$server_ip,$session_name,$one_mysql_log);}
|
||||
|
||||
+15
-5
@@ -1010,7 +1010,8 @@ if (isset($_GET["track_in_vdac"])) {$track_in_vdac=$_GET["track_in_vdac"];}
|
||||
elseif (isset($_POST["track_in_vdac"])) {$track_in_vdac=$_POST["track_in_vdac"];}
|
||||
if (isset($_GET["source_menu"])) {$source_menu=$_GET["source_menu"];}
|
||||
elseif (isset($_POST["source_menu"])) {$source_menu=$_POST["source_menu"];}
|
||||
|
||||
if (isset($_GET["agentonly_callback_campaign_lock"])) {$agentonly_callback_campaign_lock=$_GET["agentonly_callback_campaign_lock"];}
|
||||
elseif (isset($_POST["agentonly_callback_campaign_lock"])) {$agentonly_callback_campaign_lock=$_POST["agentonly_callback_campaign_lock"];}
|
||||
|
||||
if (isset($script_id)) {$script_id= strtoupper($script_id);}
|
||||
if (isset($lead_filter_id)) {$lead_filter_id = strtoupper($lead_filter_id);}
|
||||
@@ -1199,6 +1200,7 @@ $menu_timeout = ereg_replace("[^0-9]","",$menu_timeout);
|
||||
$menu_time_check = ereg_replace("[^0-9]","",$menu_time_check);
|
||||
$track_in_vdac = ereg_replace("[^0-9]","",$track_in_vdac);
|
||||
$menu_repeat = ereg_replace("[^0-9]","",$menu_repeat);
|
||||
$agentonly_callback_campaign_lock = ereg_replace("[^0-9]","",$agentonly_callback_campaign_lock);
|
||||
|
||||
### DIGITS and COLONS
|
||||
$shift_length = ereg_replace("[^\:0-9]","",$shift_length);
|
||||
@@ -1740,11 +1742,12 @@ $dialplan_entry = ereg_replace(";","",$dialplan_entry);
|
||||
# 90429-0542 - Added 3rd&4th options to SURVEY campaigns
|
||||
# 90430-0154 - Added RANDOM and LAST CALL TIME options to lead order for campaigns
|
||||
# 90504-0901 - Added Call Menu feature, changed script to use long PHP tags
|
||||
# 90511-0910 - Added agentonly_callback_campaign_lock to system_settings
|
||||
#
|
||||
# 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-182';
|
||||
$build = '90504-0901';
|
||||
$admin_version = '2.2.0-183';
|
||||
$build = '90511-0910';
|
||||
|
||||
$STARTtime = date("U");
|
||||
$SQLdate = date("Y-m-d H:i:s");
|
||||
@@ -5164,6 +5167,11 @@ FR_SPAC 00 00 00 00 00 - France space separated phone number<BR>
|
||||
<BR>
|
||||
<B>Agent interface API Access Active -</B> This option allows you to enable or disable the agent interface API. Default is 0.
|
||||
|
||||
<BR>
|
||||
<A NAME="settings-agentonly_callback_campaign_lock">
|
||||
<BR>
|
||||
<B>Agent Only Callback Campaign Lock -</B> This option defines whether AGENTONLY callbacks are locked to the campaign that the agent originally created them under. Setting this to 1 means that the agent can only dial them from the campaign they were set under, 0 means that the agent can access them no matter what campaign they are logged into. Default is 1.
|
||||
|
||||
<BR>
|
||||
<A NAME="settings-qc_features_active">
|
||||
<BR>
|
||||
@@ -11511,7 +11519,7 @@ if ($ADD==411111111111111)
|
||||
|
||||
echo "<br>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';";
|
||||
$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',agentonly_callback_campaign_lock='$agentonly_callback_campaign_lock';";
|
||||
$rslt=mysql_query($stmt, $link);
|
||||
|
||||
### LOG INSERTION Admin Log Table ###
|
||||
@@ -18819,7 +18827,7 @@ if ($ADD==311111111111111)
|
||||
echo "<TABLE><TR><TD>\n";
|
||||
echo "<FONT FACE=\"ARIAL,HELVETICA\" COLOR=BLACK SIZE=2>";
|
||||
|
||||
$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 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,agentonly_callback_campaign_lock from system_settings;";
|
||||
$rslt=mysql_query($stmt, $link);
|
||||
$row=mysql_fetch_row($rslt);
|
||||
$version = $row[0];
|
||||
@@ -18856,6 +18864,7 @@ if ($ADD==311111111111111)
|
||||
$qc_features_active = $row[31];
|
||||
$outbound_autodial_active = $row[32];
|
||||
$outbound_calls_per_second = $row[33];
|
||||
$agentonly_callback_campaign_lock = $row[34];
|
||||
|
||||
echo "<br>MODIFY VICIDIAL SYSTEM SETTINGS<form action=$PHP_SELF method=POST>\n";
|
||||
echo "<input type=hidden name=ADD value=411111111111111>\n";
|
||||
@@ -18912,6 +18921,7 @@ if ($ADD==311111111111111)
|
||||
echo "<option selected value=\"$vdc_header_phone_format\">$vdc_header_phone_format</option>\n";
|
||||
echo "</select>$NWB#settings-vdc_header_phone_format$NWE</td></tr>\n";
|
||||
echo "<tr bgcolor=#B6D3FC><td align=right>Agent API Active: </td><td align=left><select size=1 name=vdc_agent_api_active><option>1</option><option>0</option><option selected>$vdc_agent_api_active</option></select>$NWB#settings-vdc_agent_api_active$NWE</td></tr>\n";
|
||||
echo "<tr bgcolor=#B6D3FC><td align=right>Agent Only Callback Campaign Lock: </td><td align=left><select size=1 name=agentonly_callback_campaign_lock><option>1</option><option>0</option><option selected>$agentonly_callback_campaign_lock</option></select>$NWB#settings-agentonly_callback_campaign_lock$NWE</td></tr>\n";
|
||||
echo "<tr bgcolor=#B6D3FC><td align=right>QC Features Active: </td><td align=left><select size=1 name=qc_features_active><option>1</option><option>0</option><option selected>$qc_features_active</option></select>$NWB#settings-qc_features_active$NWE</td></tr>\n";
|
||||
echo "<tr bgcolor=#B6D3FC><td align=right>Outbound Auto-Dial Active: </td><td align=left><select size=1 name=outbound_autodial_active><option>1</option><option>0</option><option selected>$outbound_autodial_active</option></select>$NWB#settings-outbound_autodial_active$NWE</td></tr>\n";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user