[rt-users] Configuring a workflow action

David J. Schnardthorst daves at wavesco.com
Sun Sep 26 18:58:19 EDT 2004


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
Yes.
 
 
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')  {
    return(1);
} else {
    return(undef);
}

Stage: TransactionCreate
Template: GlobalTemplate: Create invoice ticket on resolve
 
 
 
==============================
 
 
In the template I have the following:
==============================
 
 
===Create-Ticket: Invoice
Subject: Ticket to be invoiced {$Tickets{'TOP'}->Subject}
Queue: Accounting
RefersTo: TOP
Content: 
 
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} >
 
ENDOFCONTENT

 
 
==============================
 
Any help would be greatly appreciated in resolving this problem.
 
David J. Schnardthorst
Waves Corporation
Phone: 314.974.0932 / Fax: 636.410-0630
Email:  <mailto:daves at wavesco.com> daves at wavesco.com
 <http://www.wavesco.com/> http://www.wavesco.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20040926/b18bdbb7/attachment.htm>


More information about the rt-users mailing list