How to make visible the catalog item to particular work groups(u_work_group) not assignment group.

swathi44
Tera Contributor

I have a catalog item with name "sap2010 signin". I need to make visible this catalog item to particular work groups(u_work_group). Group names are like "network" and "database". How can i achieve it?

Note: workgroups not assignment groups.

We have work group variable in user profiles...if user have access to that group like network or database then user able to see that sap2010 catalog item

Can anyone please suggest or help me?? Thanks in advance!!

5 REPLIES 5

Mohith Devatte
Tera Sage
Tera Sage

hello @swathi indhireddy ,

you can create user criteria for this .

1)OPen your maintain item and scroll down to related lists and you can see available for related list under that create a new record like below .

Here you can give your groups and save the record.

find_real_file.png

find_real_file.png

Hi Mohith, Thanks for the response..my requirement is to visible the catalog items to particular workgroups not assignment groups...both fields are different in this scenario.... We have to write script...can you help for this case?

We have work group variable in user profiles...if user have access to that group like network then user able to see that sap2010 catalog item.

hello swathi,

so in that case i am assuming that you are storing work profiles in a custom field on the user table is yes you can try below script 

answer=false
isWorkProfile();

function isWorkProfile(){
var user = new GlideRecord('sys_user');
user.addQuery('sys_id',gs.getUserID());
user.query();
if(user.next())
{
if (user.your_work_profile_field_name.indexOf('your_work_profile_name') >0) // replace work profile sys_id instead of name if its a reference or list collector field
{
    answer= true;
}
else
{
    answer=false;
}
}
}

Hope this helps 

please mark my answer correct if this helps you