Skip to main content

system.kanoa.inventory.updateInventoryTransactionType(inventoryTransactionTypeInfo, userId)

Updates an existing inventory transaction type record identified by inventoryTransactionTypeId within the supplied inventoryTransactionTypeInfo dictionary. Use this function to change attributes of a transaction type, such as its code, display name, or the sign applied to quantities when the transaction type is used. The update is attributed to the user specified by userId.


Parameters

inventoryTransactionTypeInfo Dictionary

- inventoryTransactionTypeIdInteger
- quantitySignString
- transactionTypeCodeString
- transactionTypeNameString

userId Integer:Id of the user executing the function


Returns

# of records modified Integer
message String None if success


Example

transactionTypeInfo = {
'inventoryTransactionTypeId': 4,
'transactionTypeCode': 'ADJ',
'transactionTypeName': 'Inventory Adjustment',
'quantitySign': '-',
}

userId = system.kanoa.security.getIDPUserId({'userName': 'SYSTEM'})
recordsModified, message = system.kanoa.inventory.updateInventoryTransactionType(transactionTypeInfo, userId)
print recordsModified, message