How do I determine if SLA Calendar should be used or Queue Calendar should be used with just a ticket info?
What I mean for Escalation calculation, one could set a SLA escalation or a Queue escalation. But that's automatic for escalation, I'm trying to do a time calculation in a GenericAgent. Given a ticket I think I could only know who the owner and responsible person.
If there are morning shifts, mid shift, graveyard shift. The calendar will be different too. Escalation calculation maybe I can leave to the otrs system. In terms of ITIL standard or usual standards how will I program the GenericAgent to choose between SLA calendar or Queue calendar if say SLA has a calendar assigned, and queueu has a different calendar ... Is there a function I can call to see how the administrator has set sys config to prioritize a calendar?
How do I determine if SLA Calendar should be used or Queue Calendar should be used with just a ticket info?
Moderator: crythias
-
- Znuny newbie
- Posts: 69
- Joined: 29 Apr 2016, 10:23
- Znuny Version: 3.2, 5
- Real Name: Dennis Cua
- Company: N/A
-
- 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: How do I determine if SLA Calendar should be used or Queue Calendar should be used with just a ticket info?
SLA has higher precedence than Queue...
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: 6
- Joined: 19 Dec 2013, 13:32
- Znuny Version: 5.0.4
- Real Name: Cristiano Barabanti
- Company: ToolsGroup
Re: How do I determine if SLA Calendar should be used or Queue Calendar should be used with just a ticket info?
And what If I set no calendar to SLA, will it use the Queue one?reneeb wrote:SLA has higher precedence than Queue...
-
- Znuny newbie
- Posts: 3
- Joined: 04 May 2017, 21:03
- Znuny Version: 3.3.14
- Real Name: Vitor Cavalcante Cotta
- Company: SolloBrasil
Re: How do I determine if SLA Calendar should be used or Queue Calendar should be used with just a ticket info?
Hi, I think I have a solution.
If you use SLA, OTRS will use the SLA calendar. We hope that when the calendar is not set up for SLA, OTRS uses the queue calendar. But this is not happening!
This is because when you use SLA, the calendar precedence is SLA -> System.
If you do not use SLA the calendar precedence is Queue -> System.
See the code on Ticker.pm
So I decide to use the precedence SLA -> Queue -> System, modifing the Ticker.pm.
This is work fine for me! Try at your own risk! Always backup first!
PS.: Sorry for my bad English!
If you use SLA, OTRS will use the SLA calendar. We hope that when the calendar is not set up for SLA, OTRS uses the queue calendar. But this is not happening!
This is because when you use SLA, the calendar precedence is SLA -> System.
If you do not use SLA the calendar precedence is Queue -> System.
See the code on Ticker.pm
Code: Select all
...
my %Escalation;
if ( $Self->{ConfigObject}->Get('Ticket::Service') && $Ticket{SLAID} ) {
%Escalation = $Self->{SLAObject}->SLAGet(
SLAID => $Ticket{SLAID},
UserID => $Param{UserID},
Cache => 1,
);
}
else {
%Escalation = $Self->{QueueObject}->QueueGet(
ID => $Ticket{QueueID},
UserID => $Param{UserID},
Cache => 1,
);
}
...
Code: Select all
...
my %Escalation;
my %Escalation_queue;
if ( $Self->{ConfigObject}->Get('Ticket::Service') && $Ticket{SLAID} ) {
%Escalation = $Self->{SLAObject}->SLAGet(
SLAID => $Ticket{SLAID},
UserID => $Param{UserID},
Cache => 1,
);
# Load queue info
%Escalation_queue = $Self->{QueueObject}->QueueGet(
ID => $Ticket{QueueID},
UserID => $Param{UserID},
Cache => 1,
);
# IF SLA CALENDAR IS EMPTY, USE QUEUE CALENDAR
if (!$Escalation{Calendar}){
$Escalation{Calendar} = $Escalation_queue{Calendar};
}
}
else {
%Escalation = $Self->{QueueObject}->QueueGet(
ID => $Ticket{QueueID},
UserID => $Param{UserID},
Cache => 1,
);
}
...
PS.: Sorry for my bad English!