Reputation: 166
Portlet was created as GenericPortlet not Spring MVC portlet.
I need get current portlet request in my bean. Is there way to achive it?
Upvotes: 0
Views: 933
Reputation: 13721
You can try
RequestAttributes attrs = RequestContextHolder.getRequestAttributes();
if (attrs instance of PortletRequestAttributes){
PortletRequest request = ((PortletRequestAttributes) attrs).getRequest();
}
Upvotes: 2