fixed bug 000008, problem with multiple CALLBK entries going LIVE in vicidial_callbacks

git-svn-id: svn://192.168.202.10@105 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2006-08-01 20:41:27 +00:00
parent 349bb9ccc6
commit b66682631c
2 changed files with 4 additions and 3 deletions
+2 -1
View File
@@ -38,6 +38,7 @@
# 60609-1451 - Added ability to filter by DNC list vicidial_dnc
# 60614-1159 - Added campaign lead recycling ability
# 60715-2251 - changed to use /etc/astguiclient.conf for configs
# 60801-1634 - Fixed Callback activation bug 000008
#
# constants
@@ -289,7 +290,7 @@ if ($CBHOLD_count > 0)
$event_string = "|CALLBACKS LISTACT|$affected_rows|";
&event_logger;
$stmtA = "UPDATE vicidial_callbacks set status='LIVE' where lead_id IN($update_leads);";
$stmtA = "UPDATE vicidial_callbacks set status='LIVE' where lead_id IN($update_leads) and status NOT IN('INACTIVE','DEAD','ARCHIVE');";
$affected_rows = $dbhA->do($stmtA);
if ($DB) {print "Scheduled Callbacks Activated: $affected_rows\n";}
$event_string = "|CALLBACKS CB ACT |$affected_rows|";
+2 -2
View File
@@ -1181,9 +1181,9 @@ if ($ACTION == 'VDADcheckINCOMING')
$rslt=mysql_query($stmt, $link);
### If CALLBK, change vicidial_callback record to INACTIVE
if ($dispo == 'CALLBK')
if (eregi("CALLBK|CBHOLD", $dispo))
{
$stmt="UPDATE vicidial_callbacks set status='INACTIVE' where lead_id='$lead_id' order by callback_id desc LIMIT 1;";
$stmt="UPDATE vicidial_callbacks set status='INACTIVE' where lead_id='$lead_id';";
if ($format=='debug') {echo "\n<!-- $stmt -->";}
$rslt=mysql_query($stmt, $link);
}