-
Type:
New Feature
-
Status: Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: liferay-faces-2.1.1-ga2, liferay-faces-3.0.1-legacy-ga2, liferay-faces-3.0.1-ga2, liferay-faces-3.1.1-ga2
-
Component/s: Liferay Faces Bridge Impl / Demos / Tests
-
Labels:None
The Portlet API provides three portlet modes:
PortletMode.VIEW
PortletMode.EDIT
PortletMode.HELP
Liferay Portal provides some additional vendor-specific portlet modes:
LiferayPortletMode.ABOUT
LiferayPortletMode.CONFIG
LiferayPortletMode.EDIT_DEFAULTS
LiferayPortletMode.EDIT_GUEST
LiferayPortletMode.PREVIEW
LiferayPortletMode.PRINT
This task involves adding support for these Liferay portlet modes.
Example usage of "Print" mode:
In WEB-INF/portlet.xml, use the following portlet class:
<portlet-class>com.liferay.faces.bridge.GenericLiferayFacesPortlet</portlet-class>
Then specify a default JSF viewId for the mode:
<init-param> <name>javax.portlet.faces.defaultViewId.print</name> <value>/views/portletViewMode.xhtml</value> </init-param>
And finally, add the print mode to the list of supported modes for the portlet:
<supports> ... <portlet-mode>print</portlet-mode> </supports>