OnCreate NotifyAdminCcs

Rt-users,

I was wondering if you could help me - I am trying to develop a Scrip custom condition that will prevent notification if a "Owner: " field has been emailed in ticket creation. We are using RT to generate tickets via email and in some cases we assign the owner on submission - the entire team that is ‘watching’ the queue does not need to receive email about tickets that already have an owner.

OnCreateNotifyAdminCc

Condition: OnCreate

Action: Notify AdminCcs

Template: Global template: Transaction

Stage: TransactionCreate

Custom condition:

my $transactionType = $self->TransactionObj->Type;

my $ticketOwner = $self->TicketObj->Owner;

if ($transactionType eq ‘Create’) {

return 1 if ($ticketOwner()->Id() != $RT::Nobody()->Id()); 

}

return 0;

Ultimately we only want to continue executing the script if the owner is NOT Nobody.

Regards Mathew

Mathew Ericson

IT Specialist (Systems Design)

Agilent Technologies, Inc.

+613 9210-5956 Tel

Hi RT Gurus,

hopefully a simple question. I’m trying to change the Ticket Tabs File, i would like to change the History Link from opening inside the normal RT window to open in a new window, like a “real” print preview.

Found this part at /ticket/elements/tabs:

_Ab => { title => loc('History'),
         path  => "Ticket/History.html?id=" . $id, },

I’m not sure how to add something like target=_blank

Any ideas?

Thanks

Torsten

Kühne + Nagel (AG & Co.) KG, Geschäftsleitung: Hans-Georg Brinkmann (Vors.), Uwe Bielang (Stellv.), Bruno Mang, Alfred Manke, Thorsten Meincke, Mark Reinhardt (Stellv.), Jens Wollesen, Rainer Wunn, Sitz: Bremen, Registergericht: Bremen, HRA 21928, USt-IdNr.: DE 812773878, Persönlich haftende Gesellschaft: Kühne & Nagel A.G., Sitz: Contern/Luxemburg Geschäftsführender Verwaltungsrat: Klaus-Michael Kühne

I’m not sure how to add something like target=_blank

Any ideas?

In 3.6.6, you’d have to change /Elements/PageLayout to understand what
to do with an OPTIONAL attribute (i.e. hash key) of ‘target’ (or
whatever). Then in Ticket/Elements/Tabs, add the ‘target’ key & value
to the hash.

See CleanlyCustomizeRT for details on how to make the structural changes
necessary to then make the programmatic changes.

Regards,

joe
Joe Casadonte
joe.casadonte@oracle.com

========== ==========
== The statements and opinions expressed here are my own and do not ==
== necessarily represent those of Oracle Corporation. ==
========== ==========

Hi Mathew,

Since you already have a scrip that has conditions that determine whether
or not to assign an owner when the ticket is created, I’d just copy those
conditions into another scrip and negate them to determine whether to send
the e-mail notification. Timing in RT scrip execution can get tricky when
one scrip is relying on another scrip having made a change. Using the same
conditions for your notification scrip doesn’t rely on the owner having
actually been changed yet. Rather than using OnCreate, though, you need to
use User-Defined for the condition.

Regards,
Gene

At 06:28 PM 3/13/2008, mathew_ericson@agilent.com wrote:

I was wondering if you could help me – I am trying to develop a Scrip
custom condition that will prevent notification if a “Owner: ”
field has been emailed in ticket creation. We are using RT to generate
tickets via email and in some cases we assign the owner on submission –
the entire team that is ‘watching’ the queue does not need to receive
email about tickets that already have an owner.

OnCreateNotifyAdminCc
Condition: OnCreate
Action: Notify AdminCcs
Template: Global template: Transaction
Stage: TransactionCreate

Custom condition:
my $transactionType = $self->TransactionObj->Type;
my $ticketOwner = $self->TicketObj->Owner;

if ($transactionType eq ‘Create’) {
return 1 if ($ticketOwner()->Id() != $RT::Nobody()->Id());
}
return 0;

Ultimately we only want to continue executing the script if the owner is
NOT Nobody.

Regards Mathew

Mathew Ericson
IT Specialist (Systems Design)
Agilent Technologies, Inc.
+613 9210-5956 Tel

Gene LeDuc, GSEC
Security Analyst
San Diego State University