Skip to main content

system.kanoa.item.addItemAssetRate

This function requires KanoaOPS module

Description

Adds the rateInfo to the itemAssetRate table. An entry in this table signifies that this item can be run on this asset (kanoaOPS).

Syntax

addItemAssetRate(rateInfo, userId)
  • Parameters
      rateInfo (Dictionary) - Dictionary containing rate information (e.g., {'itemId': 1, 'assetId': 56, 'standardRate': '100.0', 'scheduleRate': 50.0, 'itemPeriodId': 1, 'infeedUnitId': 7, 'outfeedUnitId': 5, 'wasteUnitId': 7, 'packageCount': 24, 'itemSourceId': 1, 'enabled': True}).
      userId (Integer) - User ID.
  • Returns
      itemAssetRateId (int).
  • Code Examples

    # Example Usage:
    itemAssetRateId = system.kanoa.item.addItemAssetRate({'itemId': 1, 'assetId': 56, 'standardRate': '100.0', 'scheduleRate': 50.0, 'itemPeriodId': 1, 'infeedUnitId': 7, 'outfeedUnitId': 5, 'wasteUnitId': 7, 'packageCount': 24, 'itemSourceId': 1, 'enabled': True}, 123)