Work Shifts
User interaction with standard work shifts and schedules in the system is managed through the Shift (users.%.models.shiftProperties) and Shifts (users.%.models.shifts) models, both of which are part of Iotellect Monitoring MES Core.
Shifts Model
The Shifts model (users.%.models.shifts) is an absolute reference model designed to define work shifts and exceptions from the standard work schedule. The model includes two variables: Shifts and Shift Exceptions.
Variable: Shifts
The Shifts variable (shifts) defines standard work shifts and schedules.
Field | Type | Description | ||||
|---|---|---|---|---|---|---|
key | String | Shift key — a unique value corresponding to the code name of the work shift | ||||
group | String | Group (schedule) the shift belongs to | ||||
description | String | Description | ||||
baseDateTime | Date | Start date and time of the current work week for the shift. This value is set manually when filling in the variable. It is automatically updated at the end of each work week | ||||
shift | Data Table | Standard weekly schedule for the shift — a sequence of work and non-work time intervals | ||||
Field | Type | Description | ||||
onOff | Boolean | Flag indicating whether the interval is a work or non-work period | ||||
duration | Long | Duration of the time interval, in milliseconds | ||||
breaks | Data Table | Breaks | ||||
Field | Type | Description | ||||
timeToBreak | Long | Time in milliseconds from the beginning of the interval to the start of the break | ||||
duration | Long | Duration of the break, in milliseconds | ||||
Variable: Shift Exceptions
The Shift Exceptions variable (exceptions) defines exceptions from the standard work schedule.
Field | Type | Description |
|---|---|---|
name | String | Unique name of the exception |
description | String | Description |
entity | String | Entity to which the exception applies The entity can be a specific employee (user) or a group of users specified via a context mask |
dayOff | Boolean | Flag indicating whether the exception represents a non-working day or a workday outside the standard shift |
isActive | Boolean | Flag indicating whether the exception is active |
startDate | Date | Start date and time of the exception |
endDate | Date | End date and time of the exception |
exceptionType | String | Exception type (see Schedule Exception Types model) |
Shift Model
The Shift model (users.%.models.shiftProperties) is a relative model attached to all production entities and employees (users). The model contains a single variable — Shift Properties (shiftProperties).
Field | Type | Description |
|---|---|---|
timezone | String | Time zone of the employee or production entity. <br>For production entities, the value can be inherited from a higher-level entity or the server. For employees, it can be inherited from the server |
shift | String | Shift key assigned to the employee. Displayed for employees only |
shiftGroup | String | Shift group — the schedule according to which work is performed on the production entity. Displayed for production entities only |
Core Functions
Function: Get Time Zone
The function returns the time zone of an employee or a production entity.
Function: | getTimeZone |
Permissions: | Available at the Observer permission level |
Input records: | 0 |
Input format: | |
Output records: | 1 |
Output format: | String |
Was this page helpful?