Small changes to allow for field updating in call menus from transfers

git-svn-id: svn://192.168.202.10@1752 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2011-11-05 04:59:32 +00:00
parent 148450377d
commit 79683313ae
2 changed files with 20 additions and 0 deletions
@@ -1037,6 +1037,8 @@ else
$transfer_cid = $originalCID;
if (length($action_xfer_cid) > 4)
{
$PADlead_id = sprintf("%010s", $insert_lead_id); while (length($PADlead_id) > 10) {chop($PADlead_id);}
$XXqueryCID = "Y$CIDdate$PADlead_id";
if ($action_xfer_cid =~ /CAMPAIGN/)
{
$CIDcampaign_cid='0000000000';
@@ -1180,6 +1182,8 @@ if ( ( ( ($hm < $ct_default_start) || ($hm > $ct_default_stop) ) && ($hm >= $ct_
if ($after_hours_action =~ /CALLMENU/)
{
$newcallerid = "\"$VCcallerid <$transfer_cid>\"";
if ($action_xfer_cid =~ /CLOSER/)
{$newcallerid = "\"$XXqueryCID <$transfer_cid>\"";}
$AGI->set_callerid($newcallerid);
print STDERR "Setting CID \"$newcallerid\"\n";
checkresult($result);
@@ -1432,6 +1436,8 @@ if ( ($no_agent_no_queue =~ /Y|NO_PAUSED/) || ($$MCnanque_override > 0) )
if ($no_agent_action =~ /CALLMENU/)
{
$newcallerid = "\"$VCcallerid <$transfer_cid>\"";
if ($action_xfer_cid =~ /CLOSER/)
{$newcallerid = "\"$XXqueryCID <$transfer_cid>\"";}
$AGI->set_callerid($newcallerid);
print STDERR "Setting CID \"$newcallerid\"\n";
checkresult($result);
@@ -3635,6 +3641,8 @@ while ( ($drop_timer <= $DROP_TIME) && ($wait_in_queue > 0) && ($MCdrop_override
if ($wait_time_option =~ /CALL_MENU/)
{
$newcallerid = "\"$VCcallerid <$transfer_cid>\"";
if ($action_xfer_cid =~ /CLOSER/)
{$newcallerid = "\"$XXqueryCID <$transfer_cid>\"";}
$AGI->set_callerid($newcallerid);
print STDERR "Setting CID \"$newcallerid\"\n";
checkresult($result);
@@ -4043,6 +4051,8 @@ while ( ($drop_timer <= $DROP_TIME) && ($wait_in_queue > 0) && ($MCdrop_override
if ($hold_time_option =~ /CALL_MENU/)
{
$newcallerid = "\"$VCcallerid <$transfer_cid>\"";
if ($action_xfer_cid =~ /CLOSER/)
{$newcallerid = "\"$XXqueryCID <$transfer_cid>\"";}
$AGI->set_callerid($newcallerid);
print STDERR "Setting CID \"$newcallerid\"\n";
checkresult($result);
@@ -4434,6 +4444,8 @@ if ( ($drop_timer > $DROP_TIME) || ($MCdrop_override > 0) )
if ($drop_action =~ /CALLMENU/)
{
$newcallerid = "\"$VCcallerid <$transfer_cid>\"";
if ($action_xfer_cid =~ /CLOSER/)
{$newcallerid = "\"$XXqueryCID <$transfer_cid>\"";}
$AGI->set_callerid($newcallerid);
print STDERR "Setting CID \"$newcallerid\"\n";
checkresult($result);
+8
View File
@@ -253,6 +253,14 @@ if ($outboundIVR > 0)
if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;}
$affected_rowsL = $dbhA->do($stmtA);
if ($AGILOG) {$agi_string = "-- VOIL insert: |$affected_rowsL|$uniqueid|$callerid|$campaign_id|$lead_id|$context|"; &agi_output;}
if ( (length($field)>2) && ($vicidial_list_fields =~ /\|$field\|/) )
{
$stmtA = "UPDATE vicidial_list SET $field='$dtmf' where lead_id='$lead_id';";
if ($AGILOG) {$agi_string = "|$stmtA|"; &agi_output;}
$affected_rowsL = $dbhA->do($stmtA);
if ($AGILOG) {$agi_string = "-- VL update: |$affected_rowsL|$field|$dtmf|$lead_id|$context|"; &agi_output;}
}
}
elsif ($fieldUPDATE > 0)
{