[Rt-commit] rt branch, 4.0/skip-processing-in-ticket-display, created. rt-4.0.4-180-g3502188

? sunnavy sunnavy at bestpractical.com
Wed Jan 11 03:45:21 EST 2012


The branch, 4.0/skip-processing-in-ticket-display has been created
        at  3502188a1e887d36297a2b16c25b015ba711b6d6 (commit)

- Log -----------------------------------------------------------------
commit 3502188a1e887d36297a2b16c25b015ba711b6d6
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Wed Jan 11 16:32:04 2012 +0800

    add skip processing mechanism
    
    this is quite useful to extensions that add reply forms in display page.

diff --git a/share/html/Ticket/Display.html b/share/html/Ticket/Display.html
index ba941cf..5bd58c7 100755
--- a/share/html/Ticket/Display.html
+++ b/share/html/Ticket/Display.html
@@ -137,9 +137,14 @@ if ($ARGS{'id'} eq 'new') {
 
     $TicketObj->CurrentUser->PrincipalObj->HasRights( Object => $TicketObj );
 
+    my $SkipProcessing;
+
     $m->callback( CallbackName => 'BeforeProcessArguments',
         TicketObj => $TicketObj, Tickets => $Tickets,
-        ActionsRef => \@Actions, ARGSRef => \%ARGS );
+        ActionsRef => \@Actions, ARGSRef => \%ARGS,
+        SkipProcessing => \$SkipProcessing );
+
+    if ( !$SkipProcessing ) {
     if ( defined $ARGS{'Action'} ) {
         if ($ARGS{'Action'} =~ /^(Steal|Delete|Take|SetTold)$/) {
             my $action = $1;
@@ -182,6 +187,7 @@ if ($ARGS{'id'} eq 'new') {
         );
         push @Actions, loc('Marked all messages as seen');
     }
+    }
 }
 
 

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


More information about the Rt-commit mailing list