Skip to main content

system.kanoa.lot.addLotOperation

Description

Adds a new lot operation.

Syntax

addLotOperation(lotOperationInfo, userId)

Parameters:
  • lotOperationInfo (dict)
  • userId (int)

  • Returns:
  • lotOperationId (int)
  • msg (string): None if successful
  • Dictionary

    ParameterTypeRequiredNotes
    lotOperationNamestring
    lotOperationColorstring
    allowInputLotsboolTrue if this operation can consume input lots
    allowOutputLotsboolTrue if this operation can product output lots
    enabledbool

    Code Examples

    # Example usage
    >lotOperationInfo = {'lotOperationName': 'Scrap', 'lotOperationColor': '#0000FF', allowInputLots': True, 'allowOutputLots': False, enabled': True}
    >userId = 5
    >lotOperationId, msg = system.kanoa.lot.addLotOperation(lotOperationInfo, userId)
    >print(lotOperationId)