RE: Model is null after submit, using FormComponentPanel

2012-12-07 Thread Raul
Here is the example to prove it's package it and deploy it in an application server. http://ul.to/ymfabds0 -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Model-is-null-after-submit-using-FormComponentPanel-tp4654441p4654586.html Sent from the Users forum mailing

Re: Model is null after submit, using FormComponentPanel

2012-12-07 Thread Sven Meier
Hi Raul, there are a few things to improve here: - in your case you don't need to extend FormComponentPanel - if you really want to control the textField's inputName, you have to let the component know about it - usage of models could be improved. See here for some ideas:

Re: Model is null after submit, using FormComponentPanel

2012-12-07 Thread Raul
Thanks, your suggestion solved my problem. Greetings from Spain. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Model-is-null-after-submit-using-FormComponentPanel-tp4654441p4654594.html Sent from the Users forum mailing list archive at Nabble.com.

Re: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Raul
Thanks for the reply, I tried to use the component on the form with the object CompoundPropertyModel. As follows, ccc = new CustomerAccountCode(ccc, new CompoundPropertyModelAccount(new Account(config.getCcc(; form.add(ccc); But this does the same as before, ie load

Re: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Tobias Gierke
Hi, I think you need to override FormComponentPanel#convertInput(). Cheers, Tobias Thanks for the reply, I tried to use the component on the form with the object CompoundPropertyModel. As follows, ccc = new CustomerAccountCode(ccc, new CompoundPropertyModelAccount(new

Re: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Raul
I've tried to override FormComponentPanel#convertInput (), but in the execution of this, both the method TextField#getConvertedInput () and TextField#getModelObject () return null. By the way I'm using Wicket 6.3 -- View this message in context:

RE: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Paul Bors
at FormComponentPanel's direct known subclasses: DateTimeField, MultiFileUploadField, Multiply ~ Thank you, Paul Bors -Original Message- From: Raul [mailto:ralva...@netwie.com] Sent: Thursday, December 06, 2012 10:35 AM To: users@wicket.apache.org Subject: Re: Model is null after submit

Re: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Joachim Schrod
Paul Bors wrote: I would suggest overriding FormComponentPanel#convertInput() only if your domain object can't be easily converted by Wicket given the model you have. If you're using CompoundPropertyModel and set the model on your FormComponentPanel then your TextField ID and type should be

RE: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Raul
I created a quickstart, Where I can upload it for what you may see? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Model-is-null-after-submit-using-FormComponentPanel-tp4654441p4654566.html Sent from the Users forum mailing list archive at Nabble.com.

RE: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Paul Bors
you, Paul Bors -Original Message- From: Joachim Schrod [mailto:jsch...@acm.org] Sent: Thursday, December 06, 2012 2:05 PM To: users@wicket.apache.org Subject: Re: Model is null after submit, using FormComponentPanel Paul Bors wrote: I would suggest overriding FormComponentPanel

RE: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Paul Bors
after submit, using FormComponentPanel I created a quickstart, Where I can upload it for what you may see? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Model-is-null-after-submit-using- FormComponentPanel-tp4654441p4654566.html Sent from the Users forum mailing list

Re: Model is null after submit, using FormComponentPanel

2012-12-06 Thread Joachim Schrod
Paul Bors wrote: Assuming that you don't set a model for the FormComponet won't Wicket fail back to the CompountPropertyModel of the form? Yes, for sure. But you explicitly recommended: If you're using CompoundPropertyModel and set the model on your FormComponentPanel then your TextField ID

Re: Model is null after submit, using FormComponentPanel

2012-12-05 Thread Paul BorČ™
Take a look at https://cwiki.apache.org/WICKET/working-with-wicket-models.html Okay so Account is the type of the model object and your FormComponentPanel seem to work off a CustomerAccountCodeModel: CustomerAccountCodeModel ccc = getModelObject(); If I'm understanding this right, what does

Re: Model is null after submit, using FormComponentPanel

2012-12-04 Thread Joachim Schrod
Raul wrote: Thank Col, But I have no validation, my component code is the code of the component is public class CustomerAccountCode extends FormComponentPanelAccount { private FormComponentString entity; private FormComponentString office; private

Re: Model is null after submit, using FormComponentPanel

2012-12-04 Thread Raul
I tried to use CompoundPropertyModel Account in CustomerAccountCode object constructor, and similarly -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Model-is-null-after-submit-using-FormComponentPanel-tp4654441p4654490.html Sent from the Users forum mailing list

RE: Model is null after submit, using FormComponentPanel

2012-12-03 Thread Colin Rogers
Raul, There are better qualified people to answer this, but... Are the components actually passing validation? Pre-validation the model would be null - if the validation fails the model would be null. If the component validates then the model would be updated with the valid value. Col.