Show Catalog item if the asset state is "In Stock" and Sub State is "available"

Gulfam Shafee3
Tera Expert

I want to show to catalog item on portal if the asset state is "In stock" and sub state is "available". Otherwise hide the catalog item. 

6 REPLIES 6

Mark Manders
Mega Patron

You could start with ACL's, but that would become a mess. Why not create a flow on the asset table that checks on the asset state/substate and activates the catalog item if it's available (and inactivates it, when it's not anymore). 


Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark

Hi Mark, 

 

what should be the trigger for flow?

will it work on the existing data?

You can trigger the flow on change of the asset state/substate (if asset is in stock and available, set catalog item to active, if not, to inactive). For existing data you would need a fix script (depending on how many catalog items you have). If it's not that much of which your assets are out of stock, just deactivate those catalog items and your flow will correct them on change.


Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark

Thanks Mark, 

I'll try this solution.

As of now I have created a BR on asset table. which is getting trigger on change of the asset state/substate. if the asset is not is stock it hide the catalog or portal.