why closed ticket age increasing after closing ticket
Moderator: crythias
-
- Znuny newbie
- Posts: 99
- Joined: 26 Nov 2012, 08:27
- Znuny Version: 3.1.10
- Real Name: shivendra
- Company: seml
why closed ticket age increasing after closing ticket
iam observing that after closing ticket, in age of Ticket increases with time.why it so.After closing ticket successfully it should show closing time only.but increases after closing .
it confuse customer if they observe.how we can restrict this age
and also on closed ticket no further reply can be done.
it confuse customer if they observe.how we can restrict this age
and also on closed ticket no further reply can be done.
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: why closed ticket age increasing after closing ticket
The age of the ticket is calculated by the difference of "today" and the day when the ticket was created. That difference gets bigger even after the ticket is closed. The age doesn't say anything about the time span from ticket creation to ticket closing.
If you want to show that time span, you have to do some programming.
If you want to show that time span, you have to do some programming.
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
-
- Znuny newbie
- Posts: 99
- Joined: 26 Nov 2012, 08:27
- Znuny Version: 3.1.10
- Real Name: shivendra
- Company: seml
Re: why closed ticket age increasing after closing ticket
thanks for knowledge.
iam not a programmer,so it will take time for me.so can you help me in programming for that if you have code.or either can you provide some link to change it.
iam not a programmer,so it will take time for me.so can you help me in programming for that if you have code.or either can you provide some link to change it.
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: why closed ticket age increasing after closing ticket
1) Kernel/System/Ticket.pm
Replace
with
The modifications in the TicketSearch method are quite complex... The method is either in the Ticket.pm file or in a separate TicketSearch.pm file (depends on you OTRS version)
You have to check if the "SortBy" option is "Age" and handle that option differently to all others
becomes
It's too complex to write it down in a few minutes...
Replace
Code: Select all
$Ticket{Age} = $Self->{TimeObject}->SystemTime() - $Ticket{CreateTimeUnix};
Code: Select all
my %Data = $Self->_TicketGetClosed();
$Ticket{Age} = ( $Data{Closed} || $Self->{TimeObject}->SystemTime() ) - $Ticket{CreateTimeUnix};
You have to check if the "SortBy" option is "Age" and handle that option differently to all others
Code: Select all
else {
# regular sort
$SQLSelect .= ', ' . $SortOptions{ $SortByArray[$Count] };
$SQLExt .= ' ' . $SortOptions{ $SortByArray[$Count] };
}
Code: Select all
else {
if ( $SortByArray[$Count] eq 'Age' ) {
# make inner join with ticket_history -- if it doesn't already exist
# create SQL to check if ticket has a close time. If not use 'create_time_unix' for sorting, otherwise
# use currenttime minus timespan between create time and close time
my $Condition = ' AND ... ';
$SQLExt =~ s{ORDER BY}{$Condition ORDER BY};
}
else {
# regular sort
$SQLSelect .= ', ' . $SortOptions{ $SortByArray[$Count] };
$SQLExt .= ' ' . $SortOptions{ $SortByArray[$Count] };
}
}
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
-
- Znuny newbie
- Posts: 99
- Joined: 26 Nov 2012, 08:27
- Znuny Version: 3.1.10
- Real Name: shivendra
- Company: seml
Re: why closed ticket age increasing after closing ticket
i tested for Ticket.pm but their is no change.
-
- Znuny newbie
- Posts: 99
- Joined: 26 Nov 2012, 08:27
- Znuny Version: 3.1.10
- Real Name: shivendra
- Company: seml
Re: why closed ticket age increasing after closing ticket
i changed it to your coding but it gives error
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: why closed ticket age increasing after closing ticket
Please post code and error logs. A simple "Internal server error" says nothing. The Apache error log and/or otrs log should provide more details.
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
-
- Znuny newbie
- Posts: 99
- Joined: 26 Nov 2012, 08:27
- Znuny Version: 3.1.10
- Real Name: shivendra
- Company: seml
Re: why closed ticket age increasing after closing ticket
when i past this code it gives error
else {
if ( $SortByArray[$Count] eq 'Age' ) {
# make inner join with ticket_history -- if it doesn't already exist
# create SQL to check if ticket has a close time. If not use 'create_time_unix' for sorting, otherwise
# use currenttime minus timespan between create time and close time
my $Condition = ' AND ... ';
$SQLExt =~ s{ORDER BY}{$Condition ORDER BY};
}
else {
# regular sort
$SQLSelect .= ', ' . $SortOptions{ $SortByArray[$Count] };
$SQLExt .= ' ' . $SortOptions{ $SortByArray[$Count] };
}
}
after reving this code it workign as previous.
but still ticket age going on increasing.....
else {
if ( $SortByArray[$Count] eq 'Age' ) {
# make inner join with ticket_history -- if it doesn't already exist
# create SQL to check if ticket has a close time. If not use 'create_time_unix' for sorting, otherwise
# use currenttime minus timespan between create time and close time
my $Condition = ' AND ... ';
$SQLExt =~ s{ORDER BY}{$Condition ORDER BY};
}
else {
# regular sort
$SQLSelect .= ', ' . $SortOptions{ $SortByArray[$Count] };
$SQLExt .= ' ' . $SortOptions{ $SortByArray[$Count] };
}
}
after reving this code it workign as previous.
but still ticket age going on increasing.....
-
- Znuny guru
- Posts: 5018
- Joined: 13 Mar 2011, 09:54
- Znuny Version: 6.0.x
- Real Name: Renée Bäcker
- Company: Perl-Services.de
- Contact:
Re: why closed ticket age increasing after closing ticket
1.) You didn't post any error logs yet!
2.) You didn't read my comment in the code, did you?
2.) You didn't read my comment in the code, did you?
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de