[rt-users] Callback question
Stephen Turner
sturner at MIT.EDU
Mon Nov 27 10:10:08 EST 2006
> -----Original Message-----
> From: rt-users-bounces at lists.bestpractical.com
> [mailto:rt-users-bounces at lists.bestpractical.com] On Behalf
> Of Brian Gallew
> Sent: Thursday, November 23, 2006 2:09 AM
> To: rt-users at lists.bestpractical.com
> Subject: [rt-users] Callback question
>
> First of all: callbacks are way cool. I've used them in a number of
> places and found them to be vastly superior to copying an entire page
> and modifying it. Unfortunately, this brings me to a
> problem: figuring
> out where callbacks really are being looked for. Let me
> present an example.
>
> I've created a local copy of Update.html which includes the following
> snippet of code inserted just before the end of the form:
> <& /Ticket/Elements/ShowHistory ,
> Ticket => $TicketObj,
> ShowTitle => 0,
> ShowDisplayModes => 0,
> ShowTitleBarCommands => 0,
> &>
>
>
> Obviously, my purpose here is to make the ticket history available to
> the commentor. To be even more convenient, *all* I want to
> display are
> comments. No priority updates, status changes, etc. So, I
> then created
> $RTHOME/local/html/Callbacks/CMUQ/Ticket/Update.html/SkipTrans
> action.
> My thought here is that the ShowHistory element has a callback
> (SkipTransaction) which will allow me to skip all of the
> uninteresting
> transactions. Sadly, it's *not* finding this file (verified
> by simply
> inserting syntax errors which had no effect).
>
Brian,
The path to the callback is related to the Mason component where the
callback is actually invoked, ie where you see something like
$m->comp( '/Elements/Callback', etc
In your case the SkipTransaction callback is invoked from the
/Ticket/Elements/ShowHistory component, so this is how the callback path
should be formed.
Steve
----------------------------------------
Stephen Turner
Senior Programmer/Analyst - Client Support Services
MIT Information Services and Technology (IS&T)
More information about the rt-users
mailing list