system.kanoa.cmms.addProcedure(procedureInfo, userId)
Creates a new maintenance procedure and assigns it to a procedure category. Call this function when defining a new repeatable maintenance or inspection workflow (e.g. "Weekly Conveyor Belt Inspection") that technicians will later execute step by step. All procedureInfo keys are required unless otherwise stated.
Parameters
procedureInfo Dictionary
| - enabled | Boolean | Not required. Will be set to True |
| - procedureCategoryId | Integer | |
| - procedureDescription | String | Not required |
| - procedureName | String | Name of procedure |
userId Integer:Id of the user executing the function
Returns
procedureId Integer
message String None if success
Example
userId = system.kanoa.security.getIDPUserId({'userName': 'SYSTEM'})
procedureInfo = {
'enabled': True,
'procedureCategoryId': None,
'procedureName': 'CNC Lube',
'procedureDescription': 'CNC Coolant and Lubrication Service'
}
procedureId, msg = system.kanoa.cmms.addProcedure(procedureInfo, userId)
print procedureId, msg