[rt-users] RT at a Glance

Nate Duehr nate at natetech.com
Fri Jul 22 16:58:33 EDT 2005


Daniel Jimenez wrote:
> All,
>  
> I only have 4 help desk employee's and I'm interested in display all of
> their owned tickets in the "RT at a glance" screen. If not there, then
> perhaps another screen that will show us these in a list.

You can do this pretty easily by using the overlay system.

I copied index.html into the local tree and added a number of new 
Elements scripts so the Home page is customized.

I had to modify two files, really... index.html to call the new Element 
I created, and an Element called AllNewOpenTickets.

*Actually I have others in there, but AllNewOpenTickets sounds like what 
you're trying to do.

Read up on how to use the overlay system and figure out your local 
directory structure for your distro.

On the Debian RT 3.4 release, it's in 
/usr/local/share/request-tracker3/html and works perfectly.

Anything placed in there overrides the standard ones in 
/usr/share/request-tracker3/html.


[BEWARE OF E-MAIL LINE WRAPS BELOW...]


Here's the part of the index.html I changed for reference.  You can 
compare this to the stock one.

-----

<& /Elements/Header, Title=>loc("RT at a glance"), Refresh => 
$session{'home_refresh_interval'} &>
<& /Elements/Tabs,
     current_toptab => '',
     Title=>loc("RT at a glance") &>
<& /Elements/ListActions, actions => \@results &>
<TABLE BORDER=0 WIDTH=100%>
<TR VALIGN=TOP>
<TD WIDTH=75% class="boxcontainer">
<& /Elements/MyTicketSmall &>
<BR>
<& /Elements/AllNewOpenTickets &>
<BR>
<& /Elements/AllStalledTickets &>
<BR>
</TD>
<TD class="boxcontainer">
<& /Elements/Quicksearch &>
<BR>
<& /Elements/QuickCreate &>
<BR>
<& /Elements/OldestUnowned &>
<BR>


-----

As you can see I added AllNewOpenTickets, AllStalledTickets, and 
OldestUnowned Elements.

For one of those as an example, AllNewOpenTickets looks like this, and 
is in the Elements sub-dir of the overlay directory:

-----

<&|/Elements/TitleBox,
         title => loc('[_1] oldest new or open tickets', $rows),
         title_href => "Search/Results.html".$QueryString &>
<& /Elements/TicketList,
         Format => "'<a 
href=\"$RT::WebPath/Ticket/Display.html?id=__id__\">__id_
_</a>/TITLE:#', '<a 
href=\"$RT::WebPath/Ticket/Display.html?id=__id__\">__Subjec
t__</a>/TITLE:Subject', Requestors, ExtendedStatus, LastUpdated",

         Query => $Query,
         OrderBy => 'LastUpdated',
         Order => 'ASC',
         Rows => $rows,
         ShowNavigation => 0
         &>
</&>
<%init>
my $rows = $RT::MyTicketsLength;

my $Query = " ( Status = 'new' OR Status = 'open' )";

my $QueryString = '?' . $m->comp('/Elements/QueryString',
             Query => $Query,
             Order => 'ASC',
             OrderBy => 'LastUpdated') if ($Query);

</%init>

-----

Note the only changes above are the title of the titlebox itself, and 
the fields requested and in the title.

-----

Not too hard to customize the "Home" page, I found.

Nate



More information about the rt-users mailing list