Dialog tabs and permissions
Hi all,
I am trying to create a page dialog based on the permissions. If I have tab1...tab5, I like to create the page template with the dialog having 5 tabs for the admin, and only the first 4 tabs for regular content editors.
The "granite:rendercondition" doesn't work for "cq/gui/components/authoring/dialog" sling:resourceType. I wonder if it works by creating a client library. I figure that Granite.author returns "undefined" in my AEM 6.5.11 with Touch UI mode so I can't get any user info from the Granite API. My initial idea is to hide/show the tab as:
if(!Granite.author.ContentFrame.getUserID() belongs to "admin")
hide tab5
Am I missing something here?
Thanks!
-kt

