SLA requirement
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-20-2023 09:33 PM
Morning team ,
we have a requirement to create SLA Durations,
When case is created today before 2PM , sla should get attached and after 2 PM then SLA get attached next day
can someone please help me out how do i achieve this ?
1. Same Business Day if created < 2pm
2. Next Business Day if Created > 2 pm
I tried with some scripts looks lie its nor working
if (calculator.isAfter(calculator.startDateTime, "14:00:00")) {
days++;
}
calculator.calcRelativeDueDate(calculator.startDateTime, days, "16:00:00");
Need your help to fix this .
Thanks in advance ...

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-20-2023 11:03 PM
Hello @pramn
Where are you trying to write the script?
You can create a schedule for your business time and attach that schedule to you SLA, so that the SLA will be active for that duration only.
Example: if you see OOTB 8*5 weekdays schedule attached to SLA, then if any case created on weekend or outside 8 AM to 5 PM will be attached will SLA but the SLA will not consider that timing. It will start considering time only during week days in the specified time period.
https://www.youtube.com/watch?v=_KvlEzqd3KU
Let me know if I misunderstood.
Thank you,
Ali
Thank you,
Ali
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-20-2023 11:23 PM
Thanks Ali,
but thr client has given 2 conditions , one is for duration and other is one for Schedule
This what making me confused.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2024 01:55 PM
Did you figure this out? I have a similar need.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-21-2024 04:16 PM
The easiest way to do this would probably be be to just create 2 sla definitions that would start upon record creation.
1 for same business day complete
1 for next business day complete
Then, add a cancel condition to both of the definition based on if the record was created was before 2pm or after 2pm, so that only the relevant one keeps running and the other one gets cancelled out. The relevant will then just continue and completes according to complete conditions. Separating the 2 also offers more benefits in regards to reporting on different sla conditions etc.