[Rt-commit] rt branch, 4.0/pass-collections-to-display-callbacks, created. rt-4.0.5-58-gab53597

Thomas Sibley trs at bestpractical.com
Wed Feb 8 14:32:06 EST 2012


The branch, 4.0/pass-collections-to-display-callbacks has been created
        at  ab535975e5aded067d14b63d61640f32149c600c (commit)

- Log -----------------------------------------------------------------
commit ab535975e5aded067d14b63d61640f32149c600c
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Wed Feb 8 14:20:48 2012 -0500

    Let a few display callbacks access the found transactions and attachments
    
    Callbacks now don't have to do their own searching, which duplicated a
    one of the slowest and heaviest queries on the page.

diff --git a/share/html/Ticket/Display.html b/share/html/Ticket/Display.html
index e2d501e..5e84a50 100755
--- a/share/html/Ticket/Display.html
+++ b/share/html/Ticket/Display.html
@@ -55,7 +55,7 @@
 <& /Elements/ListActions, actions => \@Actions &>
 <& Elements/ShowUpdateStatus, Ticket => $TicketObj &>
 
-% $m->callback( %ARGS, Ticket => $TicketObj, CallbackName => 'BeforeShowSummary' );
+% $m->callback( %ARGS, Ticket => $TicketObj, Transactions => $transactions, Attachments => $attachments, CallbackName => 'BeforeShowSummary' );
 <div class="summary">
 <&| /Widgets/TitleBox, title => loc('Ticket metadata') &>
 <& /Ticket/Elements/ShowSummary,  Ticket => $TicketObj, Attachments => $attachments &>
@@ -63,7 +63,7 @@
 </div>
 <br />
 
-% $m->callback( Ticket => $TicketObj, %ARGS, CallbackName => 'BeforeShowHistory' );
+% $m->callback( Ticket => $TicketObj, %ARGS, Transactions => $transactions, Attachments => $attachments, CallbackName => 'BeforeShowHistory' );
 
 % if (not $ForceShowHistory and RT->Config->Get( 'DeferTransactionLoading', $session{'CurrentUser'} )) {
     <& /Ticket/Elements/ClickToShowHistory,
@@ -83,6 +83,8 @@
 
 % $m->callback( %ARGS,
 %     Ticket       => $TicketObj,
+%     Transactions => $transactions,
+%     Attachments  => $attachments,
 %     CallbackName => 'AfterShowHistory',
 % );
 

-----------------------------------------------------------------------


More information about the Rt-commit mailing list