Last active
June 18, 2018 12:39
-
-
Save nosrednawall/1cd6026e282e3b15dd8bbfd69355b439 to your computer and use it in GitHub Desktop.
Atualizar campos com primefaces
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <h:form> | |
| <!-- aqui fica a declaração da tabela --> | |
| <p:dataTable id="tabela" value="#{meuBean.pessoas}" | |
| var="pessoa" | |
| paginatorTemplate="{CurrentPageReport} {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {Exporters}" | |
| paginator="true" rows="10" style="margin-bottom:20px" | |
| rowStyleClass="#{pessoa.status == 'INATIVO' ? 'inativo-row' : null}" | |
| liveResize="true" emptyMessage="Nenhum Registro Encontrado"> | |
| <!-- aqui fica o select com os status da tebela --> | |
| <f:facet name="header"> | |
| <p:outputPanel> | |
| <h:outputText value="Opções de listagem" /> | |
| <p:selectOneMenu value="#{meuBean.meusStatus}" | |
| style="width:150px" immediate="true" autoWidth="true"> | |
| <f:selectItems value="#{meuBean.meusStatus}" /> | |
| <p:ajax execute="#{meuBean.init()}" update="@form" /> | |
| </p:selectOneMenu> | |
| </p:outputPanel> | |
| </f:facet> | |
| <!-- aqui fica a tabela --> | |
| </p:datatable> | |
| </h:form> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment