I m using Liferay 6.2. in Polls Display Portlet after question is answered the polls result is displayed for all users . can we restrict the polls results to only admin users.
i m aware that some minor customization is required in \html\portlet\polls_display\view.jsp file at line 94 in this line <%@ include file="/html/portlet/polls/view_question_results.jspf" %>. but not sure how to achieve the expected results. so, can anybody please help me how to achieve this.
thanks in advance
permissionChecker.isOmniadmin()
, if you have access topermissionChecker
object. Otherwise, you can usePortalUtil.isOmniadmin(long userId)
usinguserId
fromUser
object. – Parkash KumarUser
object fromThemeDisplay
or usePortalUtil.getUser(HttpServletRequest request) / PortalUtil.getUser(PortletRequest portletRequest)
if you have anyrequest
object. – Parkash Kumar