Hi community,
I am trying to show/hide a tab based on the group of a user. EX:
User is in Managers Group of Sales Role -> he must see TAB1. Everyone else outside Managers Group of Sales Role MUST NOT see TAB1.
I already tried with object permission on Column permission, but I am not able to make it work.
Also, I saw some posts here with how to show/hide a tab, but I don't have any information about how to get the Groups for the CurrentUser.
SO: My question is: In Client Module Account, how can I retrieve the Group for CurrentUser? After that I think I can manage the logic of show/hide based on conditions.
Can you help me?
Like
Hello!
I would recommend to use Operation permission for that.
Than you can add attribute in the page schema:
"UsrCanReadSomeData": {
"dataValueType": Terrasoft.DataValueType.BOOLEAN,
"type": Terrasoft.ViewModelColumnType.VIRTUAL_COLUMN
},
and add reading this permission in init method:
RightUtilities.checkCanExecuteOperation({operation: "UsrCanReadSomeDataOperationPermission"}, function(result) {
this.set("UsrCanReadSomeData", result);
Than you can use this attribute in business rule to show/hide Tab
Kind regards,
Vladimir