Skip to main content

system.kanoa.tooling.recordReject(assetId, qty, tStamp, itemId)

Takes rejected parts off the outfeed recordProduction counted, since a tool's cycles count every part it makes. With no item, they're the running item's: the asset's Inputs/Waste Count calls this after recording them as waste. With a family tool's other item, they're also written as that item's waste (a co-product), so a vision system that knows the item calls this directly instead of writing the Waste Count.


Parameters​

assetId Integer: The asset that made the parts

qty Double: How many were rejected (0 or more)

tStamp Date: When. None = now

itemId Integer: The item rejected. None = the running item


Returns​

(countEventsWritten, message)


Example​

assetId = 1
qty = 1.0
tStamp = system.date.now()
itemId = None
countEventsWritten, message = system.kanoa.tooling.recordReject(assetId, qty, tStamp, itemId)