There's probably better ways of doing it outside of my novice experience, but I'd either hardcode in the logic to retrieve and store each value (if it's not too much work to manage it), or I'd manually call saveState on the full component tree and maybe pass that in as the value of a t:saveState component. Actually, this second approach seems the most reasonable to me, although I'm not entirely sure how you'd reconstruct the component tree when you were done.
There's also a ComponentWalker in the OptValFW that you could subclass to manually walk through each component in the tree and use to save/restore each UIInput's submitted values . On 8/25/05, Richard Wallace <[EMAIL PROTECTED]> wrote: > Mike Kienenberger wrote: > > >Sorry, I've been on vacation the last week. > > > >The default for the Optional Validation Framework is hard, so it's > >just a matter of setting validation to "none" for your command links, > >and wrapping all of your validators/converters. > > > >Note that if validation is set to none, your model isn't going to be > >updated. You'll need to pull out any values with > >getSubmittedValue(). > > > >Note that you can't have it both ways -- if you're not validating > >data, then you can't update the model since the data may not be valid. > > You really want to be preserving your submitted values, not your > >model values. > > > > > Ok, that's reasonable. How can I preserve the submitted values instead > of trying to get the model values updated so I can preserve them? > > Thanks, > Rich > > >-Mike > > > >On 8/24/05, Richard Wallace <[EMAIL PROTECTED]> wrote: > > > > > >>Hey everyone, > >> > >>I've got a form that has a couple of optional command links on it. They > >>are basically "quick add" buttons so a user can quickly add things to > >>drop downs if they aren't there. When these "quick add" buttons are > >>clicked the user is sent to an add page, the user enters the new info > >>and is then redirected back to the original page where the new entry is > >>selected and all the other data is preserved from before they clicked > >>the "quick add" button. The backing beans involved are request scoped > >>and the values filled in before clicking the "quick add" button are > >>preserved through the process using the <t:saveState> element. > >> > >>I'm trying to get the validation correct. I want all the form elements > >>to be required when the user clicks the submit button, but when they hit > >>the "quick add" link the validation should be bypassed. I thought of > >>doing this with the immediate attribute set to true on the "quick add" > >>command links but if I do that then any data the user entered on that > >>page load (contact info type stuff) is lost. So I kind of need to > >>bypass the validation but still update the model values if one of the > >>command links are clicked, but have full validation done when the > >>command button is pressed. > >> > >>I was looking at the new OptionalValidation Framework but I'm not sure > >>exactly how to apply it in this case. I mean, what I really want is to > >>have the validation type be none when command links are used and hard > >>otherwise. > >> > >>Any ideas? > >> > >>Thanks, > >>Rich > >> > >> > >> > >

