Skip to main content

system.kanoa.tooling.getHistory(paramsDict)

Returns mount history, oldest first: a tool's (toolingAssetId), or everything mounted on a machine (assetId).

By machine, the history includes every tool on it at any depth: a mold mounted on the machine, and an insert in that mold's pocket (its parentToolingAssetId is set; it's None for a tool mounted on the machine itself).


Parameters​

paramsDict Dictionary

- toolingAssetIdIntegerThe tool's mounts. One of toolingAssetId and assetId is required; both gives that tool's mounts on that machine
- assetIdIntegerEverything mounted on this machine, at any depth
- startDate
- endDateOnly mounts overlapping this window. Either end can be left open

Returns​

history pyDataset: rows of mes.vwToolingAssignment


Example​

paramsDict = {'toolingAssetId': 1, 'start': system.date.now(), 'end': system.date.now()}
history = system.kanoa.tooling.getHistory(paramsDict)

# Everything mounted on a machine over the last week, at any depth
history = system.kanoa.tooling.getHistory({'assetId': 6121, 'start': system.date.addDays(system.date.now(), -7), 'end': system.date.now()})