Forum Discussion
You can check the permission coreNode.permissions.hasPermission.
https://freemarker-docs-portal.lithium.com/refer/contextObjects
coreNode.permissions.hasPermission("property")
You just need to pass the permission name which you want to view.
e.g
<#if coreNode.permissions.hasPermission("create_thread")> <!-- usre has permission to create thread--> </#if>
Here is the list of permission names which you can pass in the content
We know this context object.
But the problem is we are unable to detect whether the user has "grant" or "allow-grant" for that permission.
Shivshankar- You can not check this with context object. May I know why do you want to know grant or allow grant? Allow and Grant permission are only given to administrator role. For all other roles, there are only Deny and Grant. You simply can check the role also.
Related Content
- 4 years ago
- 11 years ago