Description: QueueChangeHCAutoAssign
Condition: On Queue Change
Action: user Defined
Template: Global Template Transaction
Stage: Transaction Complete
Custom Condition: return 1;
Custom Action Preperation Code: return 1;
Custom Action Cleanup Code:
my $QueueName = "HealthCheck/Follow-up";
return 1 unless $self->TicketObj->QueueObj->Name eq $QueueName;
my %hash = (
'0' => 'user0',
'1' => 'user1',
'2' => 'user2',
'3' => 'user3',
'4' => 'user4',
'5' => 'user5',
'6' => 'user6',
'7' => 'user7');
my $user = $hash{int(rand(8))};
$RT::Logger->info("Auto assigning ticket #". $self->TicketObj->id ." to user $user" );
my ($status, $msg) = $self->TicketObj->SetOwner( $user );
unless( $status ) {
$RT::Logger->warning( "Impossible to assign the ticket to $user: $msg" );
return undef;
}1;Looking at the log, it seems as if this Global Scrip is never firing? Is there a problem with the On Queue Change, or Do I have something Borked up here?
Thanks,
Rodney
_______________________________________________ http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
Community help: http://wiki.bestpractical.com Commercial support: [EMAIL PROTECTED] Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com We're hiring! Come hack Perl for Best Practical: http://bestpractical.com/about/jobs.html
