diff options
Diffstat (limited to 'rt/share/html/Ticket/Elements/ShowRequestorTickets')
-rw-r--r-- | rt/share/html/Ticket/Elements/ShowRequestorTickets | 36 |
1 files changed, 13 insertions, 23 deletions
diff --git a/rt/share/html/Ticket/Elements/ShowRequestorTickets b/rt/share/html/Ticket/Elements/ShowRequestorTickets index 1213d3d50..55e781953 100644 --- a/rt/share/html/Ticket/Elements/ShowRequestorTickets +++ b/rt/share/html/Ticket/Elements/ShowRequestorTickets @@ -45,31 +45,21 @@ %# those contributions and any derivatives thereof. %# %# END BPS TAGGED BLOCK }}} -<span class="label"> - <a href="<% $url %>"><&|/l, $Rows, $Description &>This user's [_1] highest priority [_2] tickets</&>:</a> -</span> -<ul> -%while (my $w=$tickets->Next) { -%my $uri = RT::URI->new( $session{'CurrentUser'} ); -%$uri->FromObject($w); -<li class="value"><& /Elements/ShowLink, URI => $uri &></li> -%} -</ul> +<& /User/Elements/TicketList, + User => $Requestor, + conditions => $conditions, + Rows => $Rows, + Title => $Title, + WatcherTypes => ['Requestor'], + Format => => RT->Config->Get('MoreAboutRequestorTicketListFormat'), + &> <%INIT> -my $sql = "Requestor.id = ". $Requestor->id; -if (@$conditions) { - $sql .= " AND (".join( " OR ", map $_->{cond}, @$conditions).")"; -} -my $tickets = RT::Tickets->new( $session{'CurrentUser'} ); -$tickets->FromSQL( $sql ); -$tickets->RowsPerPage( $Rows ); -$tickets->OrderBy( FIELD => 'Priority', ORDER => 'DESC' ); +my $Title = loc("This user's [_1] highest priority [_2] tickets", $Rows, $Description ); -my $url = RT->Config->Get('WebPath') . '/Search/Results.html?'; - $url .= $m->comp('/Elements/QueryString', - Query => $sql, - OrderBy => 'Priority', - Order => 'DESC' ); +$m->callback( CallbackName => 'ModifyTitle', + %ARGS, + Title => \$Title +); </%INIT> <%ARGS> $Requestor => undef |