-
Type:
Bug
-
Status: Resolved
-
Resolution: Fixed
-
Affects Version/s: 7.1.0 CE GA1, 7.1.10 DXP GA1, 7.1.10 DXP FP1, 7.1.10 DXP FP2, 7.1.10 DXP FP3, 7.1.1 CE GA2, 7.1.10 DXP FP4, 7.1.10 DXP FP5, 7.1.10.1 SP1, 7.1.2 CE GA3, 7.1.10 DXP FP6, 7.1.10 DXP FP7
-
Fix Version/s: None
-
Labels:None
-
Git Pull Request:
Problem Overview
The @HeaderMethod(String portletMode) attribute is ignored, meaning all bean portlet methods annotated with @HeaderMethod are always invoked for a given portlet. Instead, such method should only be invoked if the portlet mode is not specified, or if the specified portlet mode matches the portlet mode of the incoming HeaderRequest.
The @RenderMethod(String portletMode) attribute is ignored when portletMode="" (meaning, the render method should be called for ALL portlet modes but it doesn't get called for any when the value is an empty "" string) and the attribute is also ignored when dispatching to a JSP using the @RenderMethod(String include) attribute.
Steps to Reproduce
A. Deploy the attached WAR to $LIFERAY_HOME/deploy and add it to a portal page
Expected Results
Test#1 SUCCESS: Dispatched to renderAllModes.jspx Test#2 SUCCESS Only two header methods were invoked: doHeaderViewMode doHeaderAllModes Test#3 SUCCESS The doRenderViewMode and doRenderAllModes methods were called Test#4 SUCCESS: Dispatched to renderViewMode.jspx
B. Click on the Go to "edit" mode link
Expected Results
Test#1 SUCCESS: Dispatched to renderAllModes.jspx Test#2 SUCCESS Only two header methods were invoked: doHeaderEditMode doHeaderAllModes Test#3 SUCCESS The doRenderEditMode and doRenderAllModes methods were called Test#4 SUCCESS: Dispatched to renderEditMode.jspx
C. Click on the Go BACK to "view" mode link
D. Click on the Go to "help" mode link
Expected Results
Test#1 SUCCESS: Dispatched to renderAllModes.jspx Test#2 SUCCESS Only two header methods were invoked: doHeaderHelpMode doHeaderAllModes Test#3 SUCCESS The doRenderHelpMode and doRenderAllModes methods were called Test#4 SUCCESS: Dispatched to renderHelpMode.jspx