Hide Ui actions on portal forms? How to hide button ui actions,form context menu ui actions and related links type ui actions from forms on portal view for any user either admin or non admin?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2022 12:07 PM
Hey Guys,
I activated Safe Workplace Suite that came with multiple scoped applications. I realized some weird behaviors on the portal view during my unit testing. There is an insert,insert and stay,related link and form context menu ui actions visible on the portal view for non admin users. It might not be related to the scoped applications but I just thought I mention it. I am okay to show these on the frame set but I do not want them to show on the portal at all.
I was able to disable insert and insert and stay ui action buttons on the form but for some reason related link ui actions and form context ui actions are still showing can you help on this?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2022 05:22 PM
Hi,
You can attempt to adjust the UI Action visibility on the Service Portal by getting the view name for the portal as the user is looking at the form. Then, within the respective UI Actions, in the related list at the bottom for "UI Action Visibility", you can add the view there and choose "exclude". This would prevent it from showing for that specific view.
You could also adjust those UI Actions to have the condition of:
gs.hasRole('admin')
To limit it to Admin only. You could also use the "Requires role" tab on the UI Action as well and set your role there, if that is your desire.
Keep in mind that any restricting, if it's not for a UI Action that is specific to the table involved in your question, and it's global or far reaching, any adjustment you do would also affect elsewhere within the platform. So, you may need to create a copy of these UI Actions for this specific table and then do the restrictions as mentioned above.
Please mark reply as Helpful/Correct, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2022 05:31 PM
Thanks
Thanks.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2022 05:42 PM
Hi,
The form context menu actions are mostly still UI Actions, just chosen as "context" in their settings (some come from another menu within your instance, but without specifics I can't say and I can't cover every little thing as it could be a waste of time on my end to do that). I don't know what you've tried to where it's not working. I also don't know what options are showing that you're trying to hide within the context menu anyway, unless you're trying to hide the entire menu altogether.
Please mark reply as Helpful/Correct, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2022 05:46 PM