X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=rt%2Fshare%2Fhtml%2FTicket%2FDisplay.html;h=59adbd68df1ba3db391cf345dd85a753b160c782;hb=e02e5448d8fdad322dbe5562f92d9623e5d6f0dd;hp=a6850bb1e005d4538c8597ba083c594c1dac3a2b;hpb=dd65ba99bb9281571f19744154a3b03bcd3f01ab;p=freeside.git diff --git a/rt/share/html/Ticket/Display.html b/rt/share/html/Ticket/Display.html index a6850bb1e..59adbd68d 100755 --- a/rt/share/html/Ticket/Display.html +++ b/rt/share/html/Ticket/Display.html @@ -164,9 +164,12 @@ if ($ARGS{'id'} eq 'new') { push @Actions, ProcessTicketLinks( ARGSRef => \%ARGS, TicketObj => $TicketObj ); push @Actions, ProcessTicketDates( ARGSRef => \%ARGS, TicketObj => $TicketObj ); push @Actions, ProcessTicketCustomFieldUpdates(ARGSRef => \%ARGS, TicketObj => $TicketObj ); + # If this fails due to required fields being empty, it will set + # notes('RedirectToBasics'). + push @Actions, ProcessTicketStatus( ARGSRef => \%ARGS, TicketObj => $TicketObj ); - # XXX: we shouldn't block actions here if user has no right to see the ticket, - # but we should allow him to see actions he has done + # XXX: we shouldn't block actions here if user has no right to see the + # ticket, but we should allow him to see actions he has done unless ($TicketObj->CurrentUserHasRight('ShowTicket')) { Abort("No permission to view ticket"); } @@ -197,7 +200,14 @@ if (@Actions) { my $key = Digest::MD5::md5_hex( rand(1024) ); push @{ $session{"Actions"}->{$key} ||= [] }, @Actions; $session{'i'}++; - my $url = RT->Config->Get('WebURL') . "Ticket/Display.html?id=" . $TicketObj->id . "&results=" . $key; + my $url = RT->Config->Get('WebURL'); + if ( $m->notes('RedirectToBasics') ) { + $url .= 'Ticket/Modify.html'; + } + else { + $url .= 'Ticket/Display.html'; + } + $url .= '?id=' . $TicketObj->id . "&results=" . $key; $url .= '#' . $ARGS{Anchor} if $ARGS{Anchor}; RT::Interface::Web::Redirect($url); }