[rt-users] Help with approval templates

Jeremy Winder jwinder at logicalsi.com
Mon Jun 1 18:16:17 EDT 2009


Ok, I removed the AdminCC and put the Owner: back in the template for
the General queue, just to ensure I wasn't loosing my mind. I get both
"needs approval" notifications, which I didn't realize before.

So what I want to happen is this, I want to be able to have multiple
users with the ability to approve tickets; but I only want the ticket to
require one of them. And I want the better looking default notification
emails.

Any help will be greatly appreciated. I'm trying to learn the system and
go live at the same time, which isn't a good combination.

Thanks in advance,

Jeremy

On Mon, 2009-06-01 at 17:09 -0400, Jeremy Winder wrote:
> I have been fighting this all day, I'm sure it is something simple but
> I'm completely missing it.
> 
> I had approvals setup with one person being the approver using the
> following scrip and template on my General queue:
> <scrip>
> Description: Create Approval
> Condition: On Create
> Action: Create Tickets
> Template: Approvals
> Stage: TransactionCreate
> </scrip>
> <template>
> Name: Approvals
> Description: Template used for requesting approvals
> Content:
> ===Create-Ticket: Approval
> Subject: Approval for {$Tickets{'TOP'}->Subject}
> Depended-On-By: TOP
> Queue: ___Approvals
> Type: approval
> Owner: <name-of-user>
> Content: Someone has created a ticket. you should review and approve
> it, so work can begin.
> ENDOFCONTENT 
> </template>
> 
> And all was well. I was receiving these emails as the "needs to be
> approved" notices:
> 
>         Greetings,
>         
>         There is a new item pending your approval: "CR Approval for: 9 -
>         This is a test ticket 5", 
>         a summary of which appears below.
>         
>         Please visit http://localhost/rt/Approvals/Display.html?id=10
>         to approve or reject this ticket, or
>         http://localhost/rt/Approvals/ to
>         batch-process all your pending approvals.
>         
>         -------------------------------------------------------------------------
>         Someone has created a ticket. you should review and approve it,
>         so they can finish their work
> 
> But then the fun began. I needed to it up so multiple people can approve
> a ticket but only one of them has to. So I followed the instructions at
> the bottom on http://wiki.bestpractical.com/view/ApprovalCreation and
> changed my General queue's template to be:
> <template>
> Name: Approvals
> Description: Template used for requesting approvals
> Content:
> ===Create-Ticket: Approval
> Subject: Approval for {$Tickets{'TOP'}->Subject}
> Depended-On-By: TOP
> Queue: ___Approvals
> Type: approval
> AdminCC: {
>    my $group_name  = 'Group Name';
>    my $groups      = RT::Groups->new( $RT::SystemUser );
> 
>    $groups->LimitToUserDefinedGroups();
>    $groups->Limit(
>          'FIELD'    => 'Name',
>          'OPERATOR' => '=',
>          'VALUE'    => $group_name );
>    $groups->First->Id;
> }
> Content: Someone has created a ticket. you should review and approve
> it, so work can begin.
> ENDOFCONTENT
> </template>
> 
> Now I get the emails that looks like this:
>         Mon Jun 01 16:51:24 2009: Request 35 was acted upon.
>          Transaction: Ticket created by RT_System
>                Queue: ___Approvals
>              Subject: Approval for Testing Approvials again
>                Owner: Nobody
>           Requestors: 
>               Status: new
>          Ticket <URL:
>         http://rt.logicalsi.com/rt/Ticket/Display.html?id=35 >
>         
>         
>         Someone has created a ticket. you should review and approve
>         it, so work can begin.
> 
> I realize the "new" emails I'm getting are from my template in the
> General queue and I could just copy the template from the ___Approvals
> queue over and add the AdminCC part. But I'm curious as to why adding
> the AdminCC part to my template completely changed the systems
> operation.
> 
> Thanks,
> 
> Jeremy
> 
> _______________________________________________
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
> 
> Community help: http://wiki.bestpractical.com
> Commercial support: sales at bestpractical.com
> 
> 
> Discover RT's hidden secrets with RT Essentials from O'Reilly Media. 
> Buy a copy at http://rtbook.bestpractical.com




More information about the rt-users mailing list