- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2023 11:55 AM
Hello,
I did like below :
1. Navigate to Script include -> Search script with the name "SPEntryPage ".
2. Open the script in detail, Find the function "getFirstPageURL".
3. Add role "itil" into user.hasRoles();
4. Go to sys_properties.list -> create new property
glide.entry.first.page.script
type: string
value: new SPEntryPage().getFirstPageURL();
My expect result : Only user with role 'itil' can login into Service Portal
But the result is : user without role 'itil' still can login into Service Portal
Where did I go wrong or missing?
Please help me ! Thank you so much
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2023 03:52 PM - edited 04-02-2023 03:57 PM
Hi Dinh,
This might not work because the condition you are looking at, is to make users with a specific role to go to the platform UI by default. Also, one of the problem in your code is on line 83, user.hasRoles('itil') will always come true, you need to replace it with user.hasRole('itil').
Please review below articles.
- 6 ways to set up your Service Portal for redirection SUCCESS!
- How to configure redirection for Service Portal
Thanks
Anks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2023 03:52 PM - edited 04-02-2023 03:57 PM
Hi Dinh,
This might not work because the condition you are looking at, is to make users with a specific role to go to the platform UI by default. Also, one of the problem in your code is on line 83, user.hasRoles('itil') will always come true, you need to replace it with user.hasRole('itil').
Please review below articles.
- 6 ways to set up your Service Portal for redirection SUCCESS!
- How to configure redirection for Service Portal
Thanks
Anks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-08-2023 04:09 AM
Thank you @Anks26