I am currently trying to build a page that will have a datatable that allows for filtering based on criteria set for each column. According to the documentation, the openfaces hibernateCriterionBuilder is the easiest way to accomplish this using hibernate. The builder works fine for sorting, but as soon as filtering criteria are passed it throws an error:
SEVERE: javax.el.ELException: /tools/orders/orderPicker.xhtml @24,168 value="#{orderPicker.orders}": org.hibernate.QueryException: could not resolve property: /tools/orders/orderPicker of: pojo.Orders
As far as I can tell this is a failure on part of the hibernateCriterionBuilder to properly parse the filtering data, which makes me suspect I am doing something wrong. The call to the builder is like so:
Session session = resources.HibernateUtil.getSessionFactory().openSession();
Criteria criteria = HibernateCriterionBuilder.buildCriteria(session, pojo.Orders.class);
orders = criteria.list();
From the following table:
<o:dataTable value="#{orderPicker.orders}" var="item" customDataProviding="true" totalRowCount="#{orderPicker.rowCount}" pageSize="10">
<o:column sortingExpression="#{item.distId}" id="distId" >
<f:facet name="header">
distId
</f:facet>
<f:facet name="subHeader">
<o:dropDownFieldFilter condition="beginsWith" />
</f:facet>
<h:outputText value="#{item.distId}" />
</o:column>
</o:dataTable>
Any help or insight would be appreciated.