You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Fernando Wermus <fe...@gmail.com> on 2009/11/18 20:00:23 UTC

Palette and LazyLoadingException. How to solve?

Hi all,
     I would ask how to solve a problem regarding palette component.

Palette accepts two models: one that is for showing possibles elements to
select and another one that collects users choices.

For the first case, I dont have any problem. I just use a LDM to bring back
a collection from db.


But I have a problem with the items collected by the user because I got a
LazyLoading exception.
Like they are selected by the user, I cannot use a LDM to bring them back,
they are a subset of the all posible items.
The only option that comes to mind It is to have a collection of Model for
restore the entities. But I dont like this impl. at all.

Which would be the best way to deal with items selected by the user and
OSIV?

thanks in advance.


-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus

Re: Palette and LazyLoadingException. How to solve?

Posted by Igor Vaynberg <ig...@gmail.com>.
maybe you have a model that internally converts between a list<entity>
and list<id>, storing only the list<id>

-igor

On Wed, Nov 18, 2009 at 11:00 AM, Fernando Wermus
<fe...@gmail.com> wrote:
> Hi all,
>     I would ask how to solve a problem regarding palette component.
>
> Palette accepts two models: one that is for showing possibles elements to
> select and another one that collects users choices.
>
> For the first case, I dont have any problem. I just use a LDM to bring back
> a collection from db.
>
>
> But I have a problem with the items collected by the user because I got a
> LazyLoading exception.
> Like they are selected by the user, I cannot use a LDM to bring them back,
> they are a subset of the all posible items.
> The only option that comes to mind It is to have a collection of Model for
> restore the entities. But I dont like this impl. at all.
>
> Which would be the best way to deal with items selected by the user and
> OSIV?
>
> thanks in advance.
>
>
> --
> Fernando Wermus.
>
> www.linkedin.com/in/fernandowermus
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org