List of usage examples for com.liferay.portal.kernel.security.permission ActionKeys PUBLISH_PORTLET_INFO
String PUBLISH_PORTLET_INFO
To view the source code for com.liferay.portal.kernel.security.permission ActionKeys PUBLISH_PORTLET_INFO.
Click Source Link
From source file:com.liferay.staging.configuration.web.internal.portlet.configuration.icon.StagingPortletConfigurationIcon.java
License:Open Source License
@Override public boolean isShow(PortletRequest portletRequest) { ThemeDisplay themeDisplay = (ThemeDisplay) portletRequest.getAttribute(WebKeys.THEME_DISPLAY); Group group = themeDisplay.getSiteGroup(); if (group.isStagedRemotely() || group.hasLocalOrRemoteStagingGroup()) { return false; }/*from ww w.j a v a 2 s.c o m*/ PortletDisplay portletDisplay = themeDisplay.getPortletDisplay(); String rootPortletId = portletDisplay.getRootPortletId(); if (rootPortletId.equals(ExportImportPortletKeys.EXPORT) || rootPortletId.equals(ExportImportPortletKeys.EXPORT_IMPORT) || rootPortletId.equals(ExportImportPortletKeys.IMPORT) || rootPortletId.equals(StagingConfigurationPortletKeys.STAGING_CONFIGURATION) || rootPortletId.equals(StagingProcessesPortletKeys.STAGING_PROCESSES)) { return false; } if (!portletDisplay.isShowStagingIcon()) { return false; } try { return GroupPermissionUtil.contains(themeDisplay.getPermissionChecker(), themeDisplay.getScopeGroup(), ActionKeys.PUBLISH_PORTLET_INFO); } catch (PortalException pe) { // LPS-52675 if (_log.isDebugEnabled()) { _log.debug(pe, pe); } return false; } }