Unfortunately this suggestion didn't solve the problem.

To better describe my problem:

Page A has the following content (natural order):
Id      Name
--      ----
1       Ziggy
2       Aaron

Then i sort the content by "Name":
Id      Name
--      ----
2       Aaron
1       Ziggy

Afterthat i choose for example the row with Id 2 to show the details (page B). Then i post back to page A. In this page i expect that the content is still ordered by "Name". But thats not the case, the content is displayed in the "natural" order (by Id) again.

Do you habe any ideas for this behavoir. Page A and Page B are backed by the same bean which has session scope (the content is not reloaded after during the request from page A to B and inverse).

Michael



Andrew Robinson schrieb:
Set preserveSort to false as that will make the component attempt to
store the sort state instead of letting the backing bean (in this
case) store it.

On 6/8/07, Wyder, Michael (GMX) <[EMAIL PROTECTED]> wrote:
Hi

I have 2 jsp's. Page A is the list which can be sorted, the other page B
is a detail page who shows detail of one entry from page A. My problem
is, that the choosen sort is not preserved: I do some sort on page A,
then i navigate to page B. Afterthat i navigate back to page A and i see
that the sort of the list is reseted to the default sort. Any ideas?
Both pages are backed by the same bean, which has session scope.

I made some debug and saw, that the entries in the DataModel in the
backing bean never change its order, even if i do some sort.

Here the declaration of the datatable:

<t:dataTable
        var="address"
        value="#{adresseServiceBean.addresses}"
        sortable="true"
        sortColumn="#{adresseServiceBean.sortColumn}"
        sortAscending="#{adresseServiceBean.sortAscending}"
        preserveSort="true"
        renderedIfEmpty="false">

Thanks for help!
Michael


Reply via email to