- Queue => $ARGS{'Queue'},
- Owner => $ARGS{'Owner'},
- Status => $ARGS{'Status'}||'new',
- # yes! it's Requestors, not Requestor
- Requestors => $ARGS{'Requestors'},
- From => $session{'CurrentUser'}->EmailAddress,
- Content => $ARGS{'Content'},
- Subject => $ARGS{'Subject'});
- if ( $t && $t->Id && RT->Config->Get('DisplayAfterQuickCreate', $session{'CurrentUser'}) ) {
- RT::Interface::Web::Redirect(RT->Config->Get('WebURL')."Ticket/Display.html?id=". $t->Id);
- } else {
- push @results, $msg;
+ Queue => $ARGS{'Queue'},
+ Owner => $ARGS{'Owner'},
+ Status => $ARGS{'Status'},
+ # yes! it's Requestors, not Requestor
+ Requestors => $ARGS{'Requestors'},
+ Content => $ARGS{'Content'},
+ Subject => $ARGS{'Subject'},
+ Token => $ARGS{'Token'},
+ );
+ push @results, $msg;
+
+ if ( $t && $t->Id ) {
+ $created = 1;
+ if ( RT->Config->Get('DisplayTicketAfterQuickCreate', $session{'CurrentUser'}) ) {
+ MaybeRedirectForResults(
+ Actions => \@results,
+ Path => '/Ticket/Display.html',
+ Arguments => { id => $t->Id },
+ );
+ }