-
15. Re: <rich:columns> is not working with filterBy/sortBy
pjmlp Apr 29, 2009 5:42 AM (in response to pjmlp)Hi again,
after some debugging sessions with the RichFaces source code, I discover that the problem might be somehow related with the JavaBeanWrapper class.
My filterBy expressions are being evaluated to null, even though they are properly evaluated inside the <h:outputText/> tag.
Am I not allowed to use the <h:columns> var variable inside a filterBy attribute? Why does it work for sortBy then?
Thanks in advance,
Paulo -
16. Re: <rich:columns> is not working with filterBy/sortBy
nbelaevski Apr 29, 2009 11:56 AM (in response to pjmlp)http://localhost:8080/richfaces-demo/richfaces/dataTable.jsf?tab=modifiableDataModel - works for me just fine. Have you tried the latest snapshot: http://snapshots.jboss.org/maven2/org/richfaces/samples/richfaces-demo/3.3.1-SNAPSHOT/richfaces-demo-3.3.1-20090428.040805-73.war ?
-
17. Re: <rich:columns> is not working with filterBy/sortBy
pjmlp Apr 29, 2009 11:59 PM (in response to pjmlp)Hi,
thank you very much for the WAR link. I can now see it working as well.
If I understand correctly there is no way of filterBy working on 3.3.0GA with <rich:columns/> and I will have to use 3.3.1 instead. Is that correct?
Currently my customer is using 3.3.0, and it will take some time before they are able to upgrade, that's why I am trying to get a working solution with 3.3.0.
Should I move this thread to the developer's section? -
18. Re: <rich:columns> is not working with filterBy/sortBy
nbelaevski Apr 30, 2009 12:52 AM (in response to pjmlp)Sorting does not work correctly with 3.3.0.GA: https://jira.jboss.org/jira/browse/RF-6830, so looks like you'll have to upgrade. You can try patching 3.3.0.GA version yourself: http://fisheye.jboss.org/changelog/RichFaces/trunk/ui/columns - all changes are there.
-
19. Re: <rich:columns> is not working with filterBy/sortBy
pjmlp Apr 30, 2009 6:13 AM (in response to pjmlp)Hi,
I have found a workaround for the problem.
If I have the following code:<rich:columns id="t#{indexColumn}" value="#{columnsBean.objectInstanceColumns}" var="oisColumns" index="indexColumn" sortBy="#{objInst.object[oisColumns.header]}" sortOrder="#{oisColumns.ordering}" filterBy="#{objInst.object[oisColumns.header]}" filterValue="#{oisColumns.filter}"> <f:facet name="header"> <h:outputText value="#{oisColumns.header}" /> </f:facet> <h:outputText value="#{objInst.object[oisColumns.header]}" /> </rich:columns>
The variable oisColumns does not get properly expanded in ObjectWrapFactory class. But this only happens if I reference it inside a square brackets expression, otherwise it gets properly expanded.
So I have tried to use a proper expanded version for the filterBy attribute and it now works.filterBy="#{objInst.object[columnsBean.objectInstanceColumns[indexColumn].header]}"
Is this already fixed in upcoming 3.3.1 release, or should I submit a bug report?