cmn_schedules - How to calculate how many hours are in a month?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2023 07:46 AM
We have a custom scheduling tool to schedule appointments. We are looking to see what the availability is for an office (they have a cmn_schedule record and an appointment table). Is there any way to calculate how many hours there are in a month according to their schedule? (So for example, if their schedule is set up for 8 hours every Wednesday, I'd like to know how many hours that is in the month of April).
I'm just looking for something simple as far as, how can I even gather this information? (Of course there is no huge table that this data is collected in)
I'm researching how the calendar is displayed (using a scheduled page). They use an AJAX processor:
var g = new GlideRecord('cmn_schedule');
g.addQuery('name', 'application');
g.query();
while (g.next()) {
schedulePage.addSchedule(g.sys_id, '#808080', null, true);
}
Is this possible?
Lisa
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-05-2024 09:58 AM
> Is there any way to calculate how many hours there are in a month according to their schedule?
See