I am using the P: dataTable component of Primefaces and I am having problem with the filter. I have an Email List of Sectors and within that list I have another list with the aliases of each email.
Code:
<h:panelGroup id="tabelaEmails" >
<div class="tabelaEmails" >
<p:dataTable id="tabelaFiltro" var="item" value="#{emailSetorBean.sessionBean.itemPagina.listaEmailSetor}"
widgetVar="dataWidget"
emptyMessage="Nenhum registro encontrado com os dados buscados.">
<p:column filterBy="#{item.email}" headerText="E-Mail" filterMatchMode="contains"
filterValue="#{emailSetorBean.sessionBean.filtroAlteracao}">
<h:outputText value="#{item.email}" />
</p:column>
<p:column filterBy="#{item.descricao}" headerText="Descrição" filterMatchMode="contains">
<h:outputText value="#{item.descricao}" />
</p:column>
<p:column filterBy="#{item.setor.descricao}" headerText="Setor" filterMatchMode="contains">
<h:outputText value="#{item.setor.descricao}" />
</p:column>
<p:column headerText="Alias" filterBy="#{item.listaAlias}" filterMatchMode="contains">
<h:dataTable var="alias" value="#{item.listaAlias}" >
<p:column>
<h:outputText value="#{alias.email}"/>
</p:column>
</h:dataTable>
</p:column>
</p:dataTable>
</div>
</h:panelGroup>
The last column is where the aliases are. I put filterBy="# {item.listaAlias}" only the Alias list is a mail type list, which in turn has the idGoogle and E-mail attributes. I wanted to filter by e-mail. Is there any way to do this using the component?
Thank you!