IllegalStateException on JUSearchBindingCustomizer.getViewCriteria

You are probably familiar with this use case. You have a page with a table driven by a data control. When you run this page, the data control executes and the table is populated. If you have to stop the data control from executing on page load, you put in a refresh condition like #{!adfFacesContext.initialRender} on the appropriate page binding executable.
I have a similar use case for a custom BPM worklist application in ADF for my current engagement. On successful login, a list of open tasks are displayed in a table. A POJO-based datacontrol is used to retrieve the assigned tasks. The data control was executing on page load and fetching all tasks for the default search predicate. To control this, I put in the previously mentioned refreshCondition on the relevant executable. I am greeted by the following stack trace:

I double check the refreshCondition and all relevant code to identify the problem. The second line in the stack trace is the first hint of the source of the problem. The table is sortable and filterable. The same code works well in a sample application on table with no sort or filter criteria.
Is this a bug or am I forgetting something here?

If I set the filterVisible= false on the table, the refreshCondition starts working as expected. In my case, I needed the column filters to work. Setting filterVisible to false is not an option. Notice this in the stack trace:

There is a filterable property on each column. If this property is false, the page renders successfully with no IllegalStateException. I used the same property from my managedBean to control the pagebinding executable refreshCondition and the column Filterable property.

For now, this combination appears to be working well. I will update this post if more changes are needed.

Reference: AF Column Tag

vivek

Oracle Fusion Middleware Architect at FUSION Applied
Vivek is an Oracle Certified Fusion Middleware architect. He has over 18 years of experience implementing custom software solutions in the Financial, Health, and Government sectors. He is one of the founders of Fusion Applied.
vivek

Leave a Reply

avatar
  Subscribe  
Notify of