Shift Template Demand Cover
Demand-covered-by-Shift-Templates-Check
Identifies the minimal intervals of demand that cannot be covered due to missing shift templates.
If there are any demand intervals that cannot be covered due to missing shift templates, this is returned as a warning in the feasibility response.
Warning Response Schema
title required | string Enum: "Employee-availability-check" "Demand-weekend-covered-by-employees-check" "Employee-minutes-weekly-check" "Employee-minutes-entire-roster-check" "Demand-covered-by-shift-templates-check" "Shift-is-covered-by-demand-check" "Employee-assigned-to-shift-covers-demand-check" "Shift-Templates-are-demand-relevant-check" "Shift-utilization-minimum-occurrence-check" "Locked-shift-task-requirements-check" |
category required | string This category is always set to WARNING |
description required | string |
required | Array of objects (violation) |
{- "title": "Employee-availability-check",
- "category": "string",
- "description": "string",
- "violations": [
- {
- "day": 0,
- "date": "2019-08-24",
- "demandSegment": {
- "startTime": 0,
- "endTime": 0,
- "minDemand": 0,
- "timestamp": "string"
}, - "shift": {
- "name": "string"
}, - "weekendNumber": 0,
- "requiredEmployees": 0,
- "missingEmployees": 0,
- "missingEmployeesDueToWeekendDistribution": 0,
- "employeeNumber": "string",
- "requiredMinutes": 0,
- "achievableMinutes": 0,
- "startTime": "string",
- "endTime": "string",
- "personnelGroup": "string",
- "assignment": "string",
- "taskId": "string",
- "competencies": [
- "string"
], - "workType": "string",
- "numberOfEmployees": 0,
- "missingMinutes": 0,
- "totalMinutes": 0,
- "constraintId": "string",
- "lockedShiftName": "string",
- "employeeId": "string",
- "violatedProperties": [
- "MIN"
]
}
]
}
The following fields are used in the "violation" object:
- day
- startTime
- endTime
- workType
The following payload illustrates how the response looks for a payload where the shift templates do not cover the demand.
In the example payload below, the shift templates have been replaced with shifts. This is to make it easier for the reader to follow along - but in a real-world scenario, the shifts would be generated from the shift templates, and not run for normal shifts.
This example shows a payload causing a warning during the feasibility check, with two shifts.
Shift 1 is from 08:00 to 15:00, and Shift 2 is from 13:00 to 15:00.
The demand definition requires 1 employee from 09:00 to 15:00. The demand definition is set for all days of the week.
Given that Shift 1 can never be used, as the interval goes from 08, and not from 09, the demand can never be covered from 9-13 (when the second shift starts).
- Payload
- Response
{
"jobInfo": {
"id": "xxx",
"organisationId": "xxx",
"scheduleType": "RECURRING",
"demandType": "TIME_DEMAND",
"planningHorizon": {
"startDate": "2022-01-01",
"nrOfWeeks": 1,
}
},
"shifts":[
{
"id":"Shift1",
"shiftTypes":[
"Day"
],
"intervals":[
{
"startTime":"08:00",
"endTime":"15:00",
"dayIndicator":0,
"workTypeId":"1",
"breakMinutes":30
}
]
},
{
"id":"Shift2",
"shiftTypes":[
"Day"
],
"intervals":[
{
"startTime":"13:00",
"endTime":"15:00",
"dayIndicator":0,
"workTypeId":"1"
}
]
}
],
"employees":[
{
"id":"1",
"workTime":{
"weekHoursRules":{
"minWeekHours":36,
"maxWeekHours":36
}
}
}
],
"timeSlots":[
{
"id": "time-slot-1",
"startTime": "09:00",
"endTime": "15:00",
"workTypeId": "1",
}
],
"demands":[
{
"days":{
"dayIndexes":[
0,
1,
2,
3,
4,
5,
6
]
},
"timeDemands":[
{
"timeSlotId": "time-slot-1",
"ideal": 1
}
]
}
],
"configuration":{
"workTypes":[
{
"id":"1",
"name":"WORK",
"factor":1
}
]
}
}
{
"title":"Demand-covered-by-shift-templates-check",
"category":"WARNING",
"description":"Finds the minimum number of demands interval that can't be covered due to the lack of relevant shift templates.",
"violations":[
{
"day":0,
"startTime":"09:00",
"endTime":"13:00",
"workType":"WORK"
},
{
"day":1,
"startTime":"09:00",
"endTime":"13:00",
"workType":"WORK"
},
{
"day":2,
"startTime":"09:00",
"endTime":"13:00",
"workType":"WORK"
},
{
"day":3,
"startTime":"09:00",
"endTime":"13:00",
"workType":"WORK"
},
{
"day":4,
"startTime":"09:00",
"endTime":"13:00",
"workType":"WORK"
},
{
"day":5,
"startTime":"09:00",
"endTime":"13:00",
"workType":"WORK"
},
{
"day":6,
"startTime":"09:00",
"endTime":"13:00",
"workType":"WORK"
}
]
}