Vitaly,<br><br>Sorry for the typo. This is the code we use:<br><br>Condition: User Defined<br>Action: Notify AdminCcs<br>Template: Global template: Admin Correspond<br>Stage: TransactionBatch<br><br>Custom Condition Code:<br>
# Set initial values<br><br>my $trans = $self->TransactionObj;<br>my $ticket = $self->TicketObj;<br>my $queue = $ticket->QueueObj;<br>my $requestor = $ticket->Requestors->UserMembersObj->First->PrincipalId;<br>
<br># Get out now if the requestor or owner is an AdminCc<br><br>if ($queue->AdminCc->HasMember($requestor))<br> {<br> return 0;<br> }<br><br># Get out now if the transaction is NOT a "Correspond"<br>
<br>return ($trans->Type eq "Correspond");<br><br>return 0;<br><br>Hope this helps.<br><br>Kenn<br>LBNL<br><br><div class="gmail_quote">On Mon, Jun 20, 2011 at 9:33 AM, Kenneth Crocker <span dir="ltr"><<a href="mailto:kfcrocker@lbl.gov">kfcrocker@lbl.gov</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Vitaly,<br><br>I believe you are referring to duplicate emails when the Requesdtor is also an AdminCc. Yes, I ran into that problem myself and just modifed the scrip to ignore those cases. The code is below:<br>
<br>Condition: User Defined<br>
Action: Notify AdminCcs<br>Template: Global template: Admin Correspond<br>Stage: TransactionBatch<br><br>Custom Condition Code<br># Set initial values<br><br>my $trans = $self->TransactionObj;<br>my $ticket = $self->TicketObj;<br>
my $queue = $ticket->QueueObj;<br>my $qname = substr($queue->Name, 0, 3);<br>my $owner = $ticket->OwnerObj->PrincipalId;<br>my $requestor = $ticket->Requestors->UserMembersObj->First->PrincipalId;<br>
<br># Get out now if the requestor or owner is an AdminCc<br><br>if ($queue->AdminCc->HasMember($requestor))<br> {<br> return 0;<br> }<br><br># Get out now if the transaction is NOT a "Correspond"<br>
<br>return 0 unless ($trans->Type eq "Correspond");<br><br>Hope this helps.<br><br>Kenn<br>LBNL<br><br>return 0;<div><div></div><div class="h5"><br><br><div class="gmail_quote">On Fri, Jun 17, 2011 at 11:05 PM, Vitaly Tskhovrebov <span dir="ltr"><<a href="mailto:vt@chgk.info" target="_blank">vt@chgk.info</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello.<br>
<br>
I'm using group for AdminCC the queue. Eventually, member of AdminCC created ticket, so he became requester. When owner of ticket reply him, requestor receives duplicate email notification: one for requestor, and the same for AdminCC. Is there any way to get rid of duplicate emails?<br>
<br>
RT4.<br><font color="#888888">
<br>
-- <br>
Regards, Vitaly Tskhovrebov<br>
Senior System Administrator<br>
U.S. <a href="tel:%2B1%20%28206%29%20905-9939" value="+12069059939" target="_blank">+1 (206) 905-9939</a><br>
Russia <a href="tel:%2B7%20911%20094-2035" value="+79110942035" target="_blank">+7 911 094-2035</a><br>
<br>
--------<br>
2011 Training: <a href="http://bestpractical.com/services/training.html" target="_blank">http://bestpractical.com/<u></u>services/training.html</a><br>
</font></blockquote></div><br>
</div></div></blockquote></div><br>