A little perl scrip help

To all,

I’m having trouble coding a way to extract the Queue Watcher “AdminCc” at
the time of a ticket being created as a custom condition.

Can anyone send me an example, please?

Thanks.

Kenn
LBNL

The iterator is: $Ticket->QueueObj->AdminCc->MembersObj

Cambridge Energy Alliance: Save money. Save the planet.

Jerrad,

Thanks. Can I assume then that
$Ticket->QueueObj->AdminCc->MembersObj->PrincipalId will get me the ID?

Kenn
LBNLOn Fri, Jun 18, 2010 at 11:53 AM, Jerrad Pierce < jpierce@cambridgeenergyalliance.org> wrote:

The iterator is: $Ticket->QueueObj->AdminCc->MembersObj


Cambridge Energy Alliance: Save money. Save the planet.

So you’re saying it should be this? Like I said, I’m pretty much
trying to hack my way through this. If you could complete this for me,
it would be great.

Do I need to do anything to “domain.com” to escape the “.” ?

if (($Transaction->CreatorObj->id != $RT::Nobody->id) &&
($Ticket->QueueObj->AdminCc->MembersObj !~ m/domain.com/i) &&
(!$Transaction->CreatorObj->Privileged) &&
($Transaction->CreatorObj->__Value(‘Password’) eq ‘NO-PASSWORD’)
)-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com
[mailto:rt-users-bounces@lists.bestpractical.com] On Behalf Of Jerrad
Pierce
Sent: Friday, June 18, 2010 1:53 PM
To: Kenneth Crocker
Cc: rt-users
Subject: Re: [rt-users] A little perl scrip help

The iterator is: $Ticket->QueueObj->AdminCc->MembersObj

Cambridge Energy Alliance: Save money. Save the planet.

Discover RT’s hidden secrets with RT Essentials from O’Reilly Media.
Buy a copy at http://rtbook.bestpractical.com

CONFIDENTIALITY NOTICE: The information contained in this email message, including any attachments, may be
privileged, confidential and otherwise protected from disclosure. If the reader of this message is not the
intended recipient, you are hereby notified that any use, dissemination, distribution or copying of this
message, including any attachments, is strictly prohibited. If you have received this email message in
error, please notify the sender by reply email and delete/destroy the email message, including attachments,
and any copies thereof. Although we have taken precautions to minimize the risk of transmitting viruses via
email and attachments thereto, we do not guarantee that either is virus-free, and we accept no liability for
any damages sustained as a result of any such viruses.

You’ve replied to the wrong thread.

Do I need to do anything to “domain.com” to escape the “.” ?
.

otherwise you could match domain1com.net, domain2com.org, domain3com.tld

And you should anchor it: m/domain.com$/i

Cambridge Energy Alliance: Save money. Save the planet.

Jerrad,

Thanks.

Kenn
LBNLOn Fri, Jun 18, 2010 at 12:06 PM, Jerrad Pierce < jpierce@cambridgeenergyalliance.org> wrote:

On Fri, Jun 18, 2010 at 15:00, Kenneth Crocker kfcrocker@lbl.gov wrote:

Jerrad,

Thanks. Can I assume then that
$Ticket->QueueObj->AdminCc->MembersObj->PrincipalId will get me the ID?
Umm no, ObjectID or Name. Next to iterate.


Cambridge Energy Alliance: Save money. Save the planet.