carrijo
Aug 25th, 2005, 04:22 PM
Hi folks!
I've been given the task to program an use case's flow with only two
JSPs to be exhibited upon the auspices of a controller and, 'til now,
I´ve got nothing but a headache.
As the command I have a POJO (got from a DAO) associated
bidirectionaly with another one whose contents are supposed to be
initialized and edited by a "fill-visualize-alter" sequence of steps
within the offending flow.
The problem arises in the "alter" step, in which the flow is
redirected to the initial JSP - the very one I had used to fill in the
inputs binded to the properties of the associated object. I ain't been
able to access the contents of the just initialized object, albeit I
do can access the properties of the one obtained from the DAO.
I overheard someone saying in other posts that there are two ways to
tackle the problem:
1. One might use hidden inputs in the JSP whose controls are not
binded to the command as a maneuver to force Spring to keep the
reference to that object, or
2. One can control the flow with an instance a subclass of
AbstractCommandController with its sessionForm attribute set to
true.
I´m still not convinced that the first sugestion is a good way to
handle the problem, although it solved the puzzle; whereas the second
doesn´t seem to work as I'd like it to.
Any clues?
Any criticisms?
Any sugestions?
Anyway, thanks in advance!
I've been given the task to program an use case's flow with only two
JSPs to be exhibited upon the auspices of a controller and, 'til now,
I´ve got nothing but a headache.
As the command I have a POJO (got from a DAO) associated
bidirectionaly with another one whose contents are supposed to be
initialized and edited by a "fill-visualize-alter" sequence of steps
within the offending flow.
The problem arises in the "alter" step, in which the flow is
redirected to the initial JSP - the very one I had used to fill in the
inputs binded to the properties of the associated object. I ain't been
able to access the contents of the just initialized object, albeit I
do can access the properties of the one obtained from the DAO.
I overheard someone saying in other posts that there are two ways to
tackle the problem:
1. One might use hidden inputs in the JSP whose controls are not
binded to the command as a maneuver to force Spring to keep the
reference to that object, or
2. One can control the flow with an instance a subclass of
AbstractCommandController with its sessionForm attribute set to
true.
I´m still not convinced that the first sugestion is a good way to
handle the problem, although it solved the puzzle; whereas the second
doesn´t seem to work as I'd like it to.
Any clues?
Any criticisms?
Any sugestions?
Anyway, thanks in advance!