[rt-users] Reports based on duration between open and update/closed

Christian Loos cloos at netcologne.de
Fri Mar 26 08:10:10 EDT 2010


Am 24.03.2010 14:43, schrieb Jesper Henriksen:
> Hey all,
> 
> Is there a way to get reports on how much time a ticket has been open?
> For example we would like to see the average time it takes from when a
> customer reports a problem till we have closed the ticket. Bear in mind
> that if the ticket is closed and then re-opened, the duration in which
> it was closed should not be counted.
> 
> It would also be nice if we could see how much time has passed from when
> the requestor (customer) creates or updates a ticket till one of our
> support members responds to it.
> 
> I've searched the list and google in every way I could imagine, but I
> just can't crack this nut. Can anyone help? I'm trying to setup RT for
> my new employer and these report features are critical to us.
> 

Hi Jesper,

you can do this with an callback under
local/html/Callbacks/MyCallback/Elements/RT__Ticket/ColumnMap/Once
where you extend the ticket column_map.
Attached is the callback I use, where I compare created to resolved in days.
You can then add the new field 'DaysCreatedToResolved' to the ticket
search result.

If you also want to use it within the chart feature it is a little more
difficult. You have to copy lib/RT/Report/Tickets.pm to
local/lib/RT/Report/Tickets.pm and modify it.
Attached an diff of my version BUT this only works for mysql. I also
removed some lines from the diff because I have some other modifications
in this file, so don't apply the diff, use it as an example. One
limitation that I didn't fixed is, that the days (DaysCreatedToResolved)
are not sorted in the chart.

If anyone else have done something similar, I would appreciate feedback.

Chris

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Once
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20100326/f351a3c3/attachment-0002.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Tickets.pm.diff
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20100326/f351a3c3/attachment-0003.ksh>


More information about the rt-users mailing list