Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Unanswered

SLA Business Hours / Calendar data structures

Posted on by 225

Hello Community,

I'm currently stuck on how the data model for SLAs and their Business Hours configuration works.

Requirement:

We have contracts where there are two different response times depending on when exactly the incident was reported, for example:
From 9am-5pm response time for High priority is 1 hour.
Outside of that (="24/7 minus 9-5") the response time for High priority is 2 hours.

Situation:

To accomplish that, I was planning to add a secondary SLA  field to the entitlement table. We're already assigning the SLA to the incident through a custom plugin, so I thought I'd just build on that. 
Trying to figure out the data model behind the SLA and its Business Hours configuration turns out to be a nightmare, though. So far I am able to do the following:

Retrieve the Business Hours from calendar table, using a link to also retrieve the attached calendarrule records (as this entity does not support RetrieveMultiple for some reason).
Identify the UI configuration in that record - there's
* "pattern" attribute that contains interval, frequency and weekdays, as a CSV string.
* "offset" which seems to be the offset from 0am, if the Business Hours start at 1:30am it's going to be "90"
* "duration" which seems to be the duration once offset is reached - if Business Hours started at 1:30am and endet at 2:30am, it's going to be "60"

While doing it like that seems like an odd way to do this, I thought I had finally found out how to achieve my goal - but for some reason when you look at a calendar record of type 1 (the type used for SLAs), there is NEVER an offset or duration set. 

The URL used for the classic UI configuration is https://*.crmX.dynamics.com/SM/workplans/Dialogs/TimeSheet.aspx?id=%7<id>%7d&mode=Edit&resourceid=%7b<id>%7d&oType=8&calendarid=%7b<id>%7d&calendarType=1 - but there's no table called TimeSheet or anything similar to it.

Anyone have any clue as to where this information is stored then?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans