Using ParameterHandlerMapping but Spring using command object from previous request
I am using Spring Portlet MVC. I have
Code:
<bean id="parameterHandlerMapping"
class="org.springframework.web.portlet.handler.ParameterHandlerMapping">
<property name="defaultHandler" value="addSurveyFormController"/>
<property name="parameterName" value="action"/>
<property name="parameterMap">
<map>
<entry key="newQuestion"
value-ref="addQuestionFormController" />
<entry key="assocSurveyQuestion"
value-ref="assocSurveyQuestionController" />
</map>
</property>
</bean>
Initial and very first addSurveyFormController is diplays jsp using formView. Then after submit successView shows another JSP form. In that form I set action parameter in URL and Submit it. This results in doSubmitAction of AddQuestionFormController. But I have <spring:bind> in JSP and Spring tries to use survey command which infact was command for addSurveyFormController. in AddQuestionFormController i have question command object set using property commandClass, why is it not used even when AddQuestionFormController is used. Also after completing doSubmitAction of AddQuestionFormController control again goes to onSubmitRender of AddSurveyFormController!!
_____________________
Thanks & Regards,
Advait Trivedi