I have a Form and two actions FormLoad.do and FormSave.do.  Both of these
actions have scope set to "request".

The FormLoad.do initializes the form with data by configuring various
collections (later used for options on the view), it is set to
validate="false".

The FormSave.do attempts to save the data entered by the user into the
database.  It is set to validate="true".

At this point, should the input parameter of the FormSave.do action
reference the .jsp page (view) or the FormLoad.do action?  If I reference
the .jsp page directly, the data needed by .jsp is not in the form for
display (since the new form bean was never loaded for a new request).  On
the other hand, if I reference FormLoad.do, the data is loaded, but would
user's input be saved in case of an error?  Should I change the scope of the
FormLoad.do and FormSave.do to session and have the input point to .jsp
page?  If so, when should I remove (cleanup) the bean from the session?  At
the end of the successful FormSave.do?  What if the user never presses the
submit button and just leaves the form?  Should the FormLoad.do, then also
try to remove any existing form beans from the session?

Do you put your form beans in the session or request?

I am looking for a "clean" pattern that I can use across all my Forms.
Currently, there is no set standard that I use for this type of interaction.

Thanks.

-------------
-AP_
See my profile at
http://www.myprofiles.com/member/view.do?profileId=128



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to