%#
%# COPYRIGHT:
%#
-%# This software is Copyright (c) 1996-2012 Best Practical Solutions, LLC
+%# This software is Copyright (c) 1996-2015 Best Practical Solutions, LLC
%# <sales@bestpractical.com>
%#
%# (Except where explicitly superseded by other copyright notices)
push @results, ProcessTicketBasics(TicketObj => $TicketObj, ARGSRef => \%ARGS);
push @results, ProcessObjectCustomFieldUpdates(Object => $TicketObj, ARGSRef => \%ARGS);
push @results, ProcessTicketStatus(TicketObj => $TicketObj, ARGSRef => \%ARGS);
+# for WillResolve
+push @results, ProcessTicketDates( TicketObj => $TicketObj, ARGSRef => \%ARGS);
$TicketObj->ApplyTransactionBatch;
-# TODO: display the results, even if we can't display the ticket
unless ($TicketObj->CurrentUserHasRight('ShowTicket')) {
- Abort("No permission to view ticket");
-}
+ if (@results) {
+ Abort("A change was applied successfully, but you no longer have permissions to view the ticket", Actions => \@results);
+ } else {
+ Abort("No permission to view ticket");
+ }
+}
</%INIT>
<%ARGS>