Export Context Menu in List View
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2025 01:47 AM
Use Case:
I want to hide export context menu from my custom tables if the logged in user is not member of a specific group.
I have added this line in the Export Context menu Condition:
!ListProperties.isRelatedList() && !ListProperties.isRefList() && new TestSI().disableExport(ListProperties.getTable())
Script Include:
disableExport: function(tableName) {
var groupID = gs.getProperty('Allowed_GroupID');
var tablesHidden = ['custom_table1', 'custom_table2', 'custom_table3', 'custom_table4', 'custom_table5'];
if(tablesHidden.indexOf(tableName) != -1) {
return gs.getUser().isMemberOf(groupID);
} else {
return true;
}
},
Currently its not working.
I have tried putting logs but after a time the logs are not showing even if i refresh the list view.
Need help.
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2025 06:05 AM
nope, since you overriden the OOTB global one, you will have only 1 which is yours
And in that you are adding the extra condition
If my response helped please mark it correct and close the thread so that it benefits future readers.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-05-2025 07:42 AM
i did try this but i see 2 exports in my custom table list view.