Hi Gerhard,

yes, the table's value was backed in an ArrayList in the controller. This
list could be modified and reordered, and it makes me think that the bug you
mentioned is the one I have been suffering. In ADF this worked as expected.

On the other hand, I have been able to workaround this issue by changing
this ArrayList for a ListDataModel. Anytime that there is a change in the
rows of the table (filter, delete, new search, etc.), a new ListDataModel
containing the new collection is created. This way, the row indexes seem to
be in order. If anyone needs more information about this solution, please
let me know.

Thanks for your help,

- - Rafa

On Nov 13, 2007 11:16 AM, Gerhard Petracek <[EMAIL PROTECTED]>
wrote:

> hello stephen,
>
> that's great and i'm glad that i could contribute.
>
> it's great that you described the final solution - what do you think about
> providing the community with the final working source code (via
> e-mail/blog/wiki or whatever you prefer)?
> (especially if there are(?) some minor changes which are not in the
> description)
> i think it's a common ui and someone might (sooner or later) run into the
> same problem and so it would be nice to have a short recipe in place...
> (maybe your previous posted source code and the short description are
> enough to reproduce this ui - up to now i had no time left for a close look
> at the source code...)
>
> regards,
> gerhard
>
>
>
> 2007/11/13, Stephen Friedrich <[EMAIL PROTECTED]>:
>
> > Hooray! I finally got it working.
> > Gerhard, your comments about sorting and filtering put me on the right
> > track.
> > I was naively using a simple List as backing model. After looking
> > closely
> > at Trinidad's CollectionModel and understanding the concept of row keys
> > I made my own collection model that simply uses a simple immutable
> > counter
> > on each row as a row key.
> >
> > Adding/removing rows now works fine.
> >
> > Thanks again!
> >
>
>
>
> --
>
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>

Reply via email to