maia/.svn/pristine/8f/8f6b56b00ab767c6eedbe0e45b2...

71 lines
4.4 KiB
Plaintext
Executable File

<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:c="http://java.sun.com/jstl/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:p="http://primefaces.org/ui"
xmlns:pe="http://primefaces.org/ui/extensions"
template="/WEB-INF/templates/template.xhtml"
xmlns:maia="http://java.sun.com/jsf/composite/maiaComponents">
<ui:define name="content">
<title>LOV: #{msg_customer.lvh_persons}</title>
<h:body>
<p:focus context="formTable"></p:focus>
<h:form id="formTable">
<maia:pageEvents controller="#{personViewLovController}"
queryProcess=":formTable:filters"
queryUpdate=":formTable:person"
focusContainer=":formTable:filters" />
<p:panelGrid id="filters" columns="3" styleClass="m-filters">
<f:facet name="header">
<h:outputText value="#{msg_general.lbl_filters}" />
</f:facet>
<p:outputLabel for="fpkcperson" value="#{msg_general.lbl_code}:" />
<pe:keyFilter for="fpkcperson" mask="int"/>
<p:inputText id="fpkcperson" value="#{personViewLovController.mfilters['cod_emp']}" maxlength="8" style="width: 120px;" />
<p:outputLabel for="fidenti" value="#{msg_customer.lbl_identification}:" />
<pe:keyFilter for="fpkcperson" mask="int"/>
<p:inputText id="fidenti" value="#{personViewLovController.mfilters['num_cedula']}" maxlength="15" style="width: 120px;" />
<p:outputLabel for="fname" value="#{msg_general.lbl_name}:" />
<pe:keyFilter />
<p:inputText id="fname" value="#{personViewLovController.mfilters['nombre']}" maxlength="80" style="width: 300px;" onkeyup="Maia.forceupper(event, this);"/>
<p:outputLabel for="flastname" value="#{msg_general.lbl_lastname}:" />
<pe:keyFilter />
<p:inputText id="flastname" value="#{personViewLovController.mfilters['apellido']}" maxlength="80" style="width: 300px;" onkeyup="Maia.forceupper(event, this);"/>
</p:panelGrid>
<h:panelGrid columns="7" id="controls" styleClass="m-controls">
<p:commandButton value="#{msg_general.btn_query}" update="data-content" icon="ui-icon-search" action="#{personViewLovController.query()}" process="@this, filters"/>
<p:commandButton value="#{msg_general.btn_previous}" update="data-content" icon="ui-icon-seek-prev" action="#{personViewLovController.previous()}" />
<p:commandButton value="#{msg_general.btn_next}" update="data-content" icon="ui-icon-seek-next" action="#{personViewLovController.next()}" />
</h:panelGrid>
<p:panelGrid id="data-content" columns="1" styleClass="m-data-content">
<f:facet name="header">
<h:outputText value="#{msg_customer.htbl_persons}" />
</f:facet>
<p:dataTable id="person" var="row" value="#{personViewLovController.lemployee}" rows="200" rowKey="#{row.hashCode()}" selectionMode="single" selection="#{personViewLovController.employee}" >
<p:ajax event="rowSelect" listener="#{personViewLovController.setEmployee()}" />
<p:column headerText="#{msg_general.lbl_code}" resizable="true" >
<h:outputText value="#{row[0]}" />
</p:column>
<p:column headerText="#{msg_customer.lbl_identification}" resizable="true" style="width:50px" sortBy="#{row}">
<h:outputText value="#{row[4]}" />
</p:column>
<p:column headerText="#{msg_general.lbl_name}" resizable="true" sortBy="#{row}">
<h:outputText value="#{row[2]} #{row[1]}" />
</p:column>
</p:dataTable>
</p:panelGrid>
</h:form>
</h:body>
</ui:define>
</ui:composition>