Forum Stats

  • 3,852,723 Users
  • 2,264,130 Discussions
  • 7,905,127 Comments

Discussions

Table column sort persists between task flow refreshes

MaximusDecimus
MaximusDecimus Member Posts: 130 Blue Ribbon

Hi. I'm using JDeveloper 11.1.2.4.0.

I have a bounded task flow containing a page that displays a table of data from a Tree binding. There are also 2 attribute bindings in the page def from the same iterator.

The first issue is when a column sort is applied to the table, the sort criteria remains in place even when the task flow is refreshed (from a change in the input parameters). I know the table sort criteria can be removed via an action, but how can this be performed automatically when the task flow refreshes?

The second issue is when the sort is applied on a task flow refresh, the selected table row values are inconsistent with the attribute binding values.

Any ideas please?

Thanks in advance.

Answers

  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 38,734 Red Diamond

    THe easiest way is to use a default action in the task flow. When the task flow is refreshed the default action is called again.The action points to method in a bean that reset the table.

    The code to reset the table can be found here https://tompeez.wordpress.com/2016/11/03/reset-table-filter-when-navigating-to-page/

    The second question needs more info. What exactly do you mean?

    Can you show us some images?


    Timo

  • MaximusDecimus
    MaximusDecimus Member Posts: 130 Blue Ribbon

    Hi Timo,

    Thank you very much for the reply.

    Unfortunately, your suggestion does not appear to be having any effect. I added an initial default activity to the Task Flow (prior to the Execute With Params and page fragment activities. This new activity points to a backing bean method that executes the code you suggested.

    I had to tweak the code slightly as I'm using 11g. The activity is being called, but has no effect on the table sort when the Task Flow is refreshed (by selecting another row in the calling page).

    I've also tried alternative code to reset the SortCriteria on the table (and iterator) which I also pulled from another of your blog posts. No joy.

    From the console log, I notice the VO query is executed after the reset with the table sort removed but then appears to be executed again with the sort criteria back in place?! For info, the iterator refreshes in the pagedefs for all 3 taskflow activities are set to deferred...

    The other question (which would probably be resolved by resetting the table sort), manifests itself so that the table has a row selected, while the attribute binding associated with the same iterator does not hold the same value as the selected row. The screen shot below shows the sorted table immediately after the task flow has refreshed. The selected table row (first row) is not consistent with the attribute binding inputValue displayed in the start facet and the toolbar:

    Hope that makes sense.

    Thanks again.

  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 38,734 Red Diamond