[rt-users] Can I add user info to ticket metadata?

Thomas Sibley trs at bestpractical.com
Wed Dec 29 17:48:59 EST 2010


Respond to the list please, not via personal mail.

On 29 Dec 2010 10:49, Tollefsen, Lyle wrote:
> Thanks to all who replied!
> 
> I thought I'd go with the callback method as outlined here... http://requesttracker.wikia.com/wiki/CustomizingWithCallbacks
> 
> I'm running RT 3.8.8 on Ubuntu server 10.10 and most everything is working fine so far, including authenticating from AD, but I can't get the callback to work.
> 
> What I've done to this point is create the subdirectories /opt/rt3/local/html/Callbacks/MyCallbacks/Ticket/Elements/ShowRequestor and created the file AboutThisUser in the ShowRequestor dir.  The file AboutThisUser contains "$m->callback( requestor => $requestor, %ARGS, CallbackName => 'AboutThisUser' );" as found in /opt/rt3/share/html/Ticket/Elements/ShowRequestor

Callbacks are Mason components, which are a combination of HTML and
Perl.  Copying the line from the source component which calls the
callback is just not going to work.  You're going to need to write code
in the callback (the AboutThisUser file) to display the user information
you want.

> After reloading Apache and clearing the Mason cache, the contents of AboutThisUser appears as the top line in the "More about" section of the metadata, rather than the user data.
> 
> I sure I'm missing something here but I'm at a loss as to what. Is there, perhaps, more comprehensive instructions on implemnting callbacks?

Unfortunately, I don't know of a better resource about callbacks.

Thomas

> Thanks.
> 
> Lyle
> 
> -----Original Message-----
> From: rt-users-bounces at lists.bestpractical.com [mailto:rt-users-bounces at lists.bestpractical.com] On Behalf Of Thomas Sibley
> Sent: Monday, December 20, 2010 9:11 AM
> To: rt-users at lists.bestpractical.com
> Subject: Re: [rt-users] Can I add user info to ticket metadata?
> 
> On 20 Dec 2010 09:31, Tollefsen, Lyle wrote:
>> Is it possible to include users Identity, Location and Phone numbers
>> info in the ticket metadata? I know I can grant ShowConfigTab and
>> AdminUsers to give access to this info, but I want access to be read
>> only and, ideally, visible when a ticket is opened. Can this be done?
> 
> You could easily do this in 3.8.8 by writing a callback for
> share/html/Ticket/Elements/ShowRequestor.  The callback you'd want to
> hook is probably "AboutThisUser".
> 
> As a side note, RT 4.0 will have a much more configurable requestor
> display box.
> 
> Thomas




More information about the rt-users mailing list