就像我在标题中所说,我有两个动作(studentAction
,UpdateStudentAction
)一,动作形式: studentForm
和struts-config,如:
<action path="/student"
type="action.StudentAction"
name="studentForm"
scope="request"
validate="true"
input="tiles.etudiant"
parameter="dispatch">
<forward name="UpdateStudent" path="/updateStudent.do" redirect="true" />
</action>
<action path="/updateStudent"
type="action.UpdateStudentAction"
scope="request"
name="studentForm"
input="tiles.modifierEtudiant"
parameter="dispatch">
</action>
重定向的第一个操作方法
public ActionForward onModifier(
ActionMapping mapping,
ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws DatabaseFailureException {
StudentForm studentForm=(StudentForm)form;
return mapping.findForward("UpdateStudent");
}
第二种行动方法(收件人):
public ActionForward onInitialiser(
ActionMapping mapping,
ActionForm form,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws DatabaseFailureException {
StudentForm studentForm=(StudentForm)form;
//etudiantForm.setIdEtudiantSelectionne("1");
List listeCriteres=new ArrayList();
listeCriteres.add(new SearchBean(new Etudiant().HQL_ID_ETUDIANT(), etudiantForm.getIdEtudiantSelectionne())); etudiantForm.setListeEtudiants(getReferenceDataService().findListBoParCriteres(Etudiant.class, listeCriteres));
return mapping.getInputForward(); }
**这是问题,第二个动作从第一个动作中得到一个空表单**我该如何解决这个问题?!