- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2024 10:23 AM
I am looking for assitance with away to create a user critiera profile based on the title of a users profile. I need to only allow users with "HR" in their title under their users profile to see a form in the service catalog. Is there away to use a script to get this to work?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2024 11:00 AM - edited 04-25-2024 11:08 AM
@EcFuhrmann The script which I have provided validates if the title contains "HR" (indexOf) and only those users will be able to access it.
Below is another e.g,
if (title.indexOf('vp') > -1 || title.indexOf('director') > -1 || title.indexOf('manager') > -1) {
return true;
}
return false;
}
Note: Converted the title to lowercase and have used in above "If" condition.
Please mark this as helpful and accept it as a solution if this resolves your query.
Thanks,
Sujatha V.M.
Sujatha V.M.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2024 11:13 AM
Thank you for the help!