How to implement advanced filtering
x490812 Nov 10, 2008 6:03 PMI have an extendeddatatable and each of the 11 columns has a sortBy on the column and a filterBy on the column. This works well, EXCEPT, that I want to be able toa add external filtering logic to SOME of the columns and leave built-in filtering for the others. Is this possible, Or do I have to scrap the extended datatable and use a datatable and do everything manually?
The filtering example shows a column Group in the header facet of the table for external filtering, and inputTexts in the header facets of the columns. With Built-In filtering, it shows header facets in the columns holding the column name - not the input text box. How do you reconcile these 2 different models so that you can have built-in for some columns and external for other columns?
Here is some of my code - the processMonth column (2nd) is the one on which I would like to use external filtering logic.
<rich:extendedDataTable value="#{taxSummaryList.resultList}" var="tax" id="taxSumTbl" width="100%" height="400px" sortMode="single" columnsWidth="0*"> <rich:column width="25" sortBy="#{tax.id}" filterBy="#{tax.id}" filterEvent="onkeyup"> <f:facet name="header"> <h:outputText value="Id" style="font-size:xx-small;"/> </f:facet> <s:link view="/tax_summary_item.xhtml" value="#{tax.id}"> <f:param name="tsID" value="#{tax.id}" /> </s:link> </rich:column> <rich:column width="85" sortBy="#{tax.processMonth}" filterBy="#{tax.processMonth}" filterEvent="onkeyup" > <f:facet name="header"> <h:outputText value="Process Month" style="font-size:xx-small;" /> </f:facet> <h:outputText value="#{tax.processMonth}" style="font-size:xx-small;"> <f:convertDateTime type="date" dateStyle="short"/> </h:outputText> </rich:column> <rich:column width="85" sortBy="#{tax.percentOfUpb}" filterBy="#{tax.percentOfUpb}" filterEvent="onkeyup"> <f:facet name="header"> <h:outputText value="Percent of UPB" style="font-size:xx-small;" /> </f:facet> <h:outputText value="#{tax.percentOfUpb}" style="font-size:xx-small;" > <f:convertNumber type="percent" maxFractionDigits="4" /> </h:outputText> </rich:column> . . .