Skip to main content

system.kanoa.lot.addRoute(routeInfo, userId)

Add a route. A route can be associated with an itemId or an itemClassId


Parameters

routeInfo Dictionary: All keys are required unless otherwise stated.

- enabledBoolean
- itemClassIdIntegerAn itemId or an itemClassId is required
- itemIdIntegerAn itemId or an itemClassId is required
- routeDescriptionStringNot required
- routeNameString

userId Integer


Returns

# of records modified Integer
message String None if success


Example

userId=123
# Add a new route linked to an item
routeInfo = {
"routeName": "Assembly Line 3",
"routeDescription": "Primary assembly route for Widget C",
"itemId": 102,
"itemClassId": None,
"enabled": True
}
routeId, msg = system.kanoa.lot.addRoute(routeInfo, userId)

# Add a route linked by item class
routeInfo = {
"routeName": "Final Packaging",
"routeDescription": "Packaging workflow for consumer products",
"itemId": None,
"itemClassId": 205,
"enabled": True
}
routeId, msg = system.kanoa.lot.addRoute(routeInfo, userId)