2

We recently migrated from Spiceworks to RT4. In Spiceworks, you could set it to where it auto assigns a ticket upon an tech's reply or use email tags to assign it to another tech.

Is there a way to accomplish this functionality in RT4?

I assume some perl is involved and I would like to get the web portal to auto assign an owner upon a reply at a minimum.

EDIT:

Assigning owner on comment solved by adding a new global script:

Condition: On Correspond
Action: User Defined
Template: Blank
Stage: TransCreate

And by placing this code in "Custom action preparation code:"

my $Actor = $self->TransactionObj->CreatorObj->Id;
if( $Actor != $self->TicketObj->OwnerObj->Id ) { 
$RT::Logger->info("Auto assign ticket #". $self->TicketObj->id ." to user #". $Actor ); 
my ($status, $msg) = $self->TicketObj->SetOwner( $Actor );
unless( $status ) { die "Error: $msg"; 
}
} 
return 1;

One of the caveats I encountered was that if the creator of the ticket was a tech, it would assign the ticket to nobody. Worked if the commentor was another tech.

The email commands were solved by Nathan C's post.

HopelessN00b
  • 54,273
AWippler
  • 1,077

2 Answers2

2

There's an extension to allow this: http://search.cpan.org/dist/RT-Extension-CommandByMail/

Installs on RT4 and should work out of the box.

Nathan C
  • 15,223
2

To assign owner on reply you can create a scrip and have it run on Correspond or Comment or both. For the scrip action, you can see an example of setting owner on the community RT wiki. Variations are to only set it if the current owner is 'Nobody'. You can add more debug statements while experimenting to see what's happening. Make sure you set your log level to 'debug' so you see the messages.