Re: How to have custom components interact with CompoundPropertyModel?

2011-05-29 Thread huberc
Hi, i tried adding that call in my constuctor but the call to this.getModel() still returns null before and after setType. I figure this should not happen in the constructor at all, right? On Sat, 28 May 2011, andrea del bene wrote: Hi, Have you called setType(Calendar.class) in your

Re: How to have custom components interact with CompoundPropertyModel?

2011-05-29 Thread huberc
I use the following constructor code: public DateDropDownChoice(final String id) { this(id, null); } public DateDropDownChoice(final String id, IModelCalendar model) { super(id); //.. set default values to children

how handle confirm password field with CompoundPropertyModel ?

2011-05-29 Thread Mathilde Pellerin
Hi all, I have a subcription form with a CompoundPropertyModel like this : FormMembre inscriptionForm = new FormMembre(inscriptionForm, new CompoundPropertyModelMembre(new LoadableDetachableModelMembre() { @Override protected Membre

Re: how handle confirm password field with CompoundPropertyModel ?

2011-05-29 Thread Sven Meier
Hi, a component acquires a model from a CompoundPropertyModel only if you don't explicitly provide one. Thus your example should work just fine: PasswordTextField confirmPwdField = new PasswordTextField(confirmPassword, new ModelString()); What do you mean by it didn't work ? Sven On

Re: how handle confirm password field with CompoundPropertyModel ?

2011-05-29 Thread Mathilde Pellerin
You are right : when I tested I didn't use new Model with the good component ! Sorry for disturbing... 2011/5/29 Sven Meier s...@meiers.net Hi, a component acquires a model from a CompoundPropertyModel only if you don't explicitly provide one. Thus your example should work just fine:

Re: How to have custom components interact with CompoundPropertyModel?

2011-05-29 Thread andrea del bene
You shouldn't care about passing model from parent to child-children. If I understood right your situation you should have a panel (parent of DateDropDownChoice) where you have set a CompoundPropertyModel binded to an object containing a calendar (i.e. setDefaultModel(new

Re: How to have custom components interact with CompoundPropertyModel?

2011-05-29 Thread huberc
You shouldn't care about passing model from parent to child-children. If I understood right your situation you should have a panel (parent of DateDropDownChoice) where you have set a CompoundPropertyModel binded to an object containing a calendar (i.e. setDefaultModel(new