Hello, I added some documentation to the @struts tags, because I think Nicks problem (see below) originated in missing documentation for the "@struts.dynaform-field" tag (you can override the generated property name with the "name" attribute of this method level tag).
I did not open a JIRA issue on this one, but I think it's so trivial it should be ok. Hopefully this will make it into the 1.2.2 release... Kind regards, Ren� > -----Urspr�ngliche Nachricht----- > Von: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] Auftrag von Nick > Heudecker > Gesendet: Montag, 20. September 2004 03:08 > An: [EMAIL PROTECTED] > Betreff: [Xdoclet-devel] Validating Nested Properties > > > All: > > After working on the validation code for DynaForms, I'm a bit stumped > on how to provide support for validating nested properties. For > instance, if I have a Person class which has an Address property, my > validation would look like: > > <form name="personForm"> > <field property="firstName" depends="required"> > <arg0 key="first.name"/> > </field> > <field property="lastName" depends="required"> > <arg0 key="last.name"/> > </field> > <field property="homeAddress.address1" depends="required"> > <arg0 key="home.address.1"/> > </field> > <field property="homeAddress.city" depends="required"> > <arg0 key="home.address.city"/> > </field> > <field property="homeAddress.zip" depends="required"> > <arg0 key="home.address.zip"/> > </field> > </form> > > However, I'm unable to get the template to create the "homeAddress." > prefix. My generated validation looks like: > > <form name="personForm"> > <field property="firstName" depends="required"> > <arg0 key="first.name"/> > </field> > <field property="lastName" depends="required"> > <arg0 key="last.name"/> > </field> > <field property="address1" depends="required"> > <arg0 key="home.address.1"/> > </field> > <field property="city" depends="required"> > <arg0 key="home.address.city"/> > </field> > <field property="zip" depends="required"> > <arg0 key="home.address.zip"/> > </field> > </form> > > Which clearly won't work, since the form property name is > "homeAddress.XXXX". The template engine checks the Address class for > the validation info, but I need a way to give the base property name. > Any thoughts on this? > > Thanks. > > -Nick > > > ------------------------------------------------------- > This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170 > Project Admins to receive an Apple iPod Mini FREE for your judgement on > who ports your project to Linux PPC the best. Sponsored by IBM. > Deadline: Sept. 24. Go here: http://sf.net/ppc_contest.php > _______________________________________________ > xdoclet-devel mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/xdoclet-devel > > ------------------------------------------------------- This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170 Project Admins to receive an Apple iPod Mini FREE for your judgement on who ports your project to Linux PPC the best. Sponsored by IBM. Deadline: Sept. 24. Go here: http://sf.net/ppc_contest.php _______________________________________________ xdoclet-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/xdoclet-devel
