On Tue, 15 Jan 2013 20:01:22 -0200, sthomps <stho...@gmail.com> wrote:

No form fragments don't appear to be what I would need.

I'm still finding my way around Tapestry so I'll try and explain a bit
better in how I use Wicket with nested forms.

I would like to have a parent form that on submit will validate all the
nested forms contained within including it's own input fields.

The nested forms in the parent form are small subsets of information that
may or may not be required for completion.

I can carve out this subset of info in a nested form (input fields and a
submit component) and as the user is completing the form, the nested form
can be validated on it's own - only that info related to the nested form is submitted and validated.

I'd suggest you to start by not using the term nested form. There's no such thing in HTML nor Tapestry. In addition, don't write Tapestry code thinking in Wicket. They share some concepts, but the implementation is radically different.

All you need to do is to create components wrapping form fields and the submit buttons. Tapestry (actually, the Form component) will take care of validation and etc. You can't have a Tapestry Form component nested inside another.

Regarding to just validating and submitting one of what you call subform, actually you can't do that in Tapestry directly, but you can work around it easily: create one component just with the fields and their validation (I'll call it Fields for this example), another one (FieldsForm) which has a template with Form component wrapping a Fields instance. Of course, you'll need more than one pair of it.

--
Thiago H. de Paula Figueiredo

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to