Configuring a workflow action

I am running Request Tracker 3.0.10 and I am attempting to configure an
action that will run on every queue, but a queue called "Accounting."
This action should On Resolve open a ticket in the accounting queue to
invoice for the time on the ticket.

The problem is, when the ticket for invoicing is resolved by the
Accounting team a new ticket is still opened. I would further like to
have the ticket only created if the custom field “Billable” is set to

In the Scrip I have the following:

Description: Open invoicing request in accounting queue
Condition: On Resolve
Action: Create Tickets
Custom action preparation code:

my $ticket = $self->TicketObj;
my $QueueName = $TicketObj->QueueObj->Name;

if ($QueueName ne ‘Accounting’) {
} else {

Stage: TransactionCreate
Template: GlobalTemplate: Create invoice ticket on resolve

In the template I have the following:

===Create-Ticket: Invoice
Queue: Accounting
RefersTo: TOP

This ticket has been closed. Please invoice as outlined below.

Billable: {$Ticket->FirstCustomFieldValue(‘Billable’);}
Service Type: {$Ticket->FirstCustomFieldValue(‘ServiceType’);}
Time Worked: {$Ticket->TimeWorked} minutes
Description: {$Tickets{‘TOP’}->Subject}
Ticket <URL: {$RT::WebURL}Ticket/Display.html?id={$Ticket->id} >


Any help would be greatly appreciated in resolving this problem.

David J. Schnardthorst
Waves Corporation
Phone: 314.974.0932 / Fax: 636.410-0630