You can solve this using Wickets PropertyModels. Map the Components
that are part
of your domain models as usual (CompoundPropertyModel?) and use
PropertyModels for the others:
TextField tf = new TextField("myWicketID", new
PropertyModel(PageOrComponent.this, "spezialAttribute"));
than provide getter and setter in your PageOrComponent class for that
spezialAttribute.
Bert
On Tue, Mar 16, 2010 at 15:19, Vladimir K wrote:
>
> Wiket provides PropertyModel class to map to values accessible via
> expressions.
> You always can write your own models. For instance you can employ Spring
> property expressions if you'd like map on collection projection.
> You can yield values using great Google collections framework.
>
>
> Steven Haines wrote:
>>
>> First, thanks for your help yesterday with the form id question,
>> setMarkupId() solved my problem.
>>
>> I have a generic page design question for you: how do you handle
>> situations when your page form does not map easily to your domain objects?
>> I can map 90% of the form's fields to my domain object, but there are a
>> couple fields from which I derive values on my domain object. I can solve
>> this by creating a Java object that maps one-to-one with my form and then
>> constructing my domain object(s) from that form object, but is there a
>> better way / best practice way of handling this situation?
>>
>> Thanks for your insight!
>> Steve
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>>
>
> --
> View this message in context:
> http://old.nabble.com/Page-Design-Question-tp27918033p27918501.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>
-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org