Fórumok
LiferayFacesContext.getPortlet() method returning null
Hasika Pamunuwa, módosítva 11 év-val korábban
LiferayFacesContext.getPortlet() method returning null
New Member Bejegyzések: 11 Csatlakozás dátuma: 2010.06.21. Legújabb bejegyzések
Following returns null when called from an action event method which is invoked by primefaces 3.2 command button. I'm using liferay-faces-portal-3.1.0-BETA2.jar and Liferay 6.1
But following worked...
LiferayFacesContext liferayFacesContext = LiferayFacesContext.getInstance();
Portlet portlet = liferayFacesContext.getPortlet(); // portlet is coming back as null
But following worked...
LiferayFacesContext liferayFacesContext = LiferayFacesContext.getInstance();
PortletRequestImpl portletRequest = (PortletRequestImpl) liferayFacesContext.getExternalContext().getRequest();
Portlet portlet = portletRequest.getPortlet();
Neil Griffin, módosítva 11 év-val korábban