[rt-users] One requirement for RT notifications

Odhiambo Washington wash at wananchi.com
Mon Oct 23 16:23:32 EDT 2006


Hi Roy,

Thank you so much for this valuable clue.

Before I posted this question, I had thoroughly scoured the wiki for 
clues, because I do remember seeing such a discussion, but I just could 
not find it!
Perhaps there is something Jesse will do to secure the wiki.


* On 23/10/06 10:53 +0100, Roy El-Hames wrote:
| Odhiambo;
| This been discussed few times before, and its on the wiki (but it 
| appears the wiki been attacked again) ..
| To add the initial request to the mail message what you need is to 
| change the Transaction template to something similar to:
| 
| RT-Attach-Message: yes
| 
| 
| This is an admin correspondence:
| {$RT::WebURL}Ticket/Display.html?id={$Ticket->id}
| 
| {$Transaction->CreatedAsString}: Request {$Ticket->id} was acted upon.
| Transaction: {$Transaction->Description}
|       Queue: {$Ticket->QueueObj->Name}
|     Subject: {$Transaction->Subject || $Ticket->Subject || "(No subject 
| given)"}
|       Owner: {$Ticket->OwnerObj->Name}
|       Ticket Queue = {$Ticket->QueueObj->Name}
|  Requestors: {$Ticket->RequestorAddresses}
|      Status: {$Ticket->Status}
| Ticket <URL: {$RT::WebURL}Ticket/Display.html?id={$Ticket->id} >
| 
| 
| This ticket is now assigned to {$Ticket->OwnerObj->Name}
| =============================================
| The initial request was:
| ====
| {
| my $cont  = '';
| my $trans = $Ticket->Transactions;
| $trans->Limit(FIELD => 'Type', VALUE => 'Create');
| while (my $tran = $trans->Next) {
|    my $attach = $tran->Attachments;
|    while (my $msg = $attach->Next){
|      next unless $msg->ContentType =~ m!^(text/plain|message|text$)!i;
|      my $content = $msg->Content;
|      next unless $content;
|      next if $cont eq $content;
|      $cont = $content;
|      my $wrapper = Text::Wrapper->new(columns=>70);
|      $cont = $wrapper->wrap($cont);
|     }  
| }
|  $cont ;
| }
| =============================================
| 
| Barry L. Kline wrote:
| >-----BEGIN PGP SIGNED MESSAGE-----
| >Hash: SHA1
| >
| >Odhiambo WASHINGTON wrote:
| >  
| >>* On 22/10/06 12:54 -0400, Barry L. Kline wrote:
| >>| -----BEGIN PGP SIGNED MESSAGE-----
| >>| Hash: SHA1
| >>| 
| >>| Odhiambo Washington wrote:
| >>| > Hello All,
| >>| > 
| >>| > I need to implement a request my users have raised regarding RT. 
| >>| > These are mainly to do with scrips, templates and display.
| >>| > My RT instance has been running so smoothly that my grasp of these 
| >>| > things has somehow faded ;)
| >>| > 
| >>| [snip]
| >>| > 
| >>| > This transaction appears to have no content
| >>| > 
| >>| > <cut>
| >>| > 
| >>| > My scrip for this is:
| >>| > 
| >>| > On Owner Change Notify Owner with template Transaction
| >>| > 
| >>| > My "Transaction" template has a last line: {$Transaction->Content()}
| >>| > 
| >>| > 
| >>| > Q: Why could it be failing to pull the ticket content?
| >>| 
| >>| I'm no expert, but I believe it's because the $Transaction object refers
| >>| to the transaction where the owner was changed.  The Content() of this
| >>| transaction is empty.  What you need to do is retrieve the ticket object
| >>| that this transaction refers to and pull its content.
| >>
| >>
| >>Hi Barry,
| >>
| >>Your explanation seems very correct!
| >>Do you have any pointers how I can achieve that though?
| >>
| >>    
| >
| >I'm afraid not.  As I said, I'm no expert on this.  You can find out
| >some more by studying the various templates in the software itself, or
| >by looking at the wiki:  http://wiki.bestpractical.com
| >
| >Barr
| >-----BEGIN PGP SIGNATURE-----
| >Version: GnuPG v1.2.6 (GNU/Linux)
| >
| >iD8DBQFFO/fpCFu3bIiwtTARAkOIAJwPxkaBnRuQT46Y4qjdsslzVn+HtQCfd9dS
| >HrekJEPylKlo/f426axL7NI=
| >=z+lp
| >-----END PGP SIGNATURE-----
| >_______________________________________________
| >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
| >
| >  

        cheers
       - wash 
+----------------------------------+-----------------------------------------+
Odhiambo Washington            		. WANANCHI ONLINE LTD (Nairobi, KE)  |
wash () WANANCHI ! com			. 1ere Etage, Loita Hse, Loita St.,  |
GSM: (+254) 722 743 223			. # 10286, 00100 NAIROBI             |
GSM: (+254) 733 744 121			. (+254) 020 313 985 - 9             |
+---------------------------------+------------------------------------------+
"Oh My God! They killed init! You Bastards!"  
						 --from a /. post



More information about the rt-users mailing list