HAM PRO Stock rules - what state/substate is counted when stock rule looks at quantity in stock room
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
When a stock rule fires and it counts the quantity of assets or consumables in a stock room to compart against the stock rule threshold, what state and/or substate is counted. For instance, if an asset is in stock and reserved is it still counted against the threshold. Or if an asset is in maintenance and no substate is it counted? Is there a table or list somewhere that defines what state and substate values are counted against the threshold?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
Hi,
The OOTB logic consists of the following
- Query alm_asset
- Filter based on model
- State (install_status) = In Stock
- Substate is available or reserved
- No active transfer order
HAM Pro adds the following into the basic query
- Asset function is not Loaner or Asset Bundle
You can read this in the StockRuleTransfer script include
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Hi @raknight
If an asset is "In Stock" and "Reserved"?
= NOT COUNTED. The substate is "Reserved," not "Available," so it is excluded from the stock rule calculation. This is by design, so that reserved items don't trigger a re-order.
If an asset is "In Maintenance" and has no substate?
=NOT COUNTED. The state is "In Maintenance," not "In Stock." Only assets in the "In Stock" state are considered.
Also, you won't find this in a simple table. The logic is defined in the script that runs the stock rules.
-
A daily scheduled job named "Stock Rule Runner" executes.
-
This job calls a Script Include (like
StockRuleTransferor a similar utility). -
(
alm_consumable) table that match the following:-
stockroom= [Your Stockroom] -
model= [Your Model] -
install_status= 6 (In stock) -
substatus= 'available'
-
This is why an asset that is "In Stock" but "Reserved" or "Pending Disposal" is correctly ignored by the stock rule.
Note: Please Mark this Helpful and Accepted Solution. If this Helps you to understand. This will help both the community and me..
- Keep Learning
Thanks & Regards
Deepak Sharma
