Environment: Liferay 6.1 GA3 EE
Can we have custom permissions defined for the portal?
We can create custom permissions in our plugin portlet through creating an XML with <portlet-resource>
tag and defining the <action-key>
within it.
And when I go to define permissions for a Role in Control Panel my portlet appears in the section Site Applications
, now what I want is to create custom permissions (not through EXT) in a portlet or hook that should have a separate category as My Custom
and should have custom permissions like <action-key>ACCESS_EMAIL</action-key>
, <action-key>ACCESS_TOOLSET<\action-key>
etc.
In short my custom category should appear within section Portal
as shown in the following figure while I define the permission for a custom Portal (regular) role:
I would like to use this permission not for a specific portlet but need to use it inside jsp-hooks or any other of my custom portlets. Just like we have ADD_SITE
, ADD_USER
etc permissions in Portal
--> General
, I want to have these permissions as generic.
Edit
To make the portlet appear in any of the section I created a simple custom-portlet, so the portlet appeared in the Site Application
section and if I want I can make it appear in the Control Panel
sections as well.
But now the problem is I don't have any view nor any implementation in this portlet so I make it hidden by updating the liferay-display.xml
and putting it under category.hidden
. This also hides it from the Define Permission
drop-down.
And if I don't use the lifeay-display.xml
liferay puts it under the Undefined
category while accessing it from +Add
menu in dockbar. :-(
Thank You