Skip to main content

system.kanoa.lot.addLotStateReason

This function is part of the kanoaOPS module

Description

Adds a new lot state reason.

Syntax

addLotStateReason(lotStateReasonInfo, userId)
  • Parameters
      lotStateReasonInfo (dict)
      - lotStateReasonName (string)
      - lotStateId (int)
      -enabled (bool)
      userId (int)
  • Returns
      lotStateReasonId (int)
      message (string): None if success
  • Code Examples

    # Example usage
    >lotStateReasonInfo = {'lotStateReasonName': 'Bad Coloring', 'lotStateId': 2, 'enabled': True}
    >lotStateReasonId, msg = system.kanoa.lot.addLotStateReason(lotStateReasonInfo, userId)
    > print(lotStateReasonId)