[ http://issues.apache.org/jira/browse/MYFACES-108?page=comments#action_59590 ] Manfred Geiler commented on MYFACES-108: ----------------------------------------
Yes, true if you have a classical "one form page". Then the submitted (invalid) value is also always part of the normal request parameters and the component could get it from there. But: Imagine a more complex page with two forms side by side. Now the user enters something in form 1 and submits it. The entered value is invalid, so the model bean is not updated yet. The submitted value gets redisplayed (somehow). Next the user does something in form 2 and submits it. Now the submitted value in form 1 will disappear, because the model does not know anything of this value and the component in form 1 would not have saved state information about the submitted value. You might say "why should someone have two forms on one page?". Well, with complex page designs (tiles) you cannot always have just one form. Imagine the following practical user interface example: One tile displays an input wizard where the user should enter some information. Another tile displays a help tile aside (perhaps a help component with index and search feature). User enters a bad value in the input form. Page is redisplayed. User uses the help component to find the reason why the entered value is not allowed. He uses the search feature of the help component, so he submits a form other than the input form. If we would not save state, all entered values would disappear now. Not very user friendly. ;-) > UIInput should not store submitted value in the state > ----------------------------------------------------- > > Key: MYFACES-108 > URL: http://issues.apache.org/jira/browse/MYFACES-108 > Project: MyFaces > Type: Improvement > Versions: 1.0.7 beta, 1.0.8 beta > Reporter: sean schofield > Priority: Trivial > > Submitted value really shouldn't be stored in the state. At a minimum it is > confusing and results in extra bandwith with client-side state saving. Heath > points out that in most cases the value being "stored" will probably be null. > That being said, if the code is totally unecessary we ought to consider > removing it. I will leave this issue open for a while to make sure nobody > has any issues with fixing it. This will affect a lot of components so I > want to be sure this is the right thing to do. I will provide a patch > eventually. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira
