Skip to main content

system.kanoa.shift.addShift(shiftInfo, userId)

Adds a new shift. All shiftInfo keys are required.


Parameters

shiftInfo Dictionary

- assetIdInteger
- shiftColorStringi.e. '#00FF00'
- shiftNameIdInteger

userId Integer: Id of user executing the function


Returns

shiftId Integer


Example

shiftInfo = {'shiftNameId': 1, 'assetId': 18, 'shiftColor': '#00FF00'}
shiftId = system.kanoa.shift.addShift(shiftInfo, 123)