0
votes

I have code below form. . i wanted to search globally. please suggest me how can i do it

            <p:ajax event="rowSelect" listener="#{employeeCategoryBean.onRowSelect}" />
            <p:ajax event="contextMenu" listener="#{employeeCategoryBean.onRowSelect}" />

            <f:facet name="header">  
                      <p:outputPanel>  
            <h:outputText value="Search all fields:" />  
            <p:inputText id="globalFilter" onkeyup="modelTable.filter()" style="width:150px" />  
        </p:outputPanel>  
                </f:facet>

            <p:column headerText="Name">
                    #{model.name}
                </p:column>

            <p:column headerText="Prefix">
                    #{model.prefix}
                </p:column>
1
I think @Uday wants this : stackoverflow.com/a/10702116/617373 - Daniel
@Daniel i hav follwed that link also but is not working. could u send complete code - Uday
add filterBy to your columns just like in showcase, than try, if wont work post your complete code in your question. - Daniel
@ Daniel, i used filterBy attribute also but it wont work. i have posted the complete code. .check out and let me know . - Uday

1 Answers