How to show catalog items on portal based on User Criteria applied.

Community Alums
Not applicable

Hi All,

 

I want to show catalog items on portal based on user criteria applied on the catalog item.

If the catalog item has any user criteria, then it should be visible only to those users who has access.

How to get the catalog items based on user criteria, Which method or API in servicenow?

 

Thanks in advance

Samidha

 

10 REPLIES 10

Hello,

 

Not sure if I am understanding something wrong here but applying the  available for/ Not available for in the related list is the same as what you are trying to achieve. and it will make sure the criteria is applied on the Portal as well.

Steven Parker
Giga Sage

Just navigate to Service Catalog -> User Criteria and define your user criteria.  You can then use that criteria in the "Available For" or "Not Available For" related list/catalog item config.

 

StevenParker_0-1667313589331.png

 

We use Departments, Users, Groups, or Roles a lot to define our User Criteria

StevenParker_1-1667313671553.png

 

 


Please mark this response as correct and/or helpful if it assisted you with your question.
Steven

Ankur Bawiskar
Tera Patron
Tera Patron

@Community Alums 

your question is confusing.

If you create user criteria and add it to catalog item in Available for related list then it will show that catalog item only when that criteria passes.

If you are talking about API then here is a link

UserCriteriaLoader - API to Evaluate User Criteria 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Community Alums
Not applicable

Hi @Ankur Bawiskar ,

If I applied the user criteria in available for of catalog item, it supposed to show as per user criteria only.

When I am trying to get the list of catalog item on portal then user criterias are not working. it is showing me the catalog which not supposed to show for specific user.

For this issue i am trying to find out any other solution where after GlideRecord all the catalog i can check for user criteria filter if its valid then only push in lust or array.

 

Thanks

Samidha

@Community Alums 

share the screenshot where you are referring this

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader