maia_modificado/.svn/pristine/2b/2bd85aa08c2a72919b24c909704...

83 lines
5.3 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">
<h:form id="formTable" enctype="multipart/form-data">
<p:panelGrid columns="1" >
<f:facet name="header">
<h:outputText value="#{msg_general.lbl_descargarsubir}" />
</f:facet>
<p:panelGrid id="documento" styleClass="m-filters">
<p:row styleClass="m-data-content">
<p:column >
<p:outputLabel value="#{msg_armas.lbl_noDocumento}" style="width:50px !important;"></p:outputLabel><br />
<p:outputLabel value="#{firmarDocumentoController.xpathflujo}" style="width:50px !important;"></p:outputLabel>
</p:column>
<p:column styleClass="m-action-column" headerText="#{msg_armas.lbl_documento}" resizable="true" style="width:50px;text-align: center;">
<maia:alfrescoDocDownload controllerAlfresco="#{firmarDocumentoController.alfrescoController}"
xPathLocation="#{firmarDocumentoController.xpathflujo}"
label="#{msg_armas.btn_descargarDocumentos}" immediate="true" />
</p:column>
<p:column styleClass="m-action-column" headerText="#{msg_armas.lbl_documento}" style="width:400px !important;" resizable="true">
<p:fileUpload fileUploadListener="#{firmarDocumentoController.upload}" update="@this, formTable:documento"
allowTypes="/(\.|\/)(pdf)$/" description="Seleccionar Archivo"
label="#{msg_armas.lbl_seleccionar}" uploadLabel="#{msg_armas.lbl_subir}"
cancelLabel="#{msg_armas.lbl_cancelar}"
fileLimit="1"
invalidFileMessage="#{msg_armas['msg_error_tipoarchivoinvalido']}"
invalidSizeMessage="#{msg_armas.lbl_mensajearchivoinvalidom} #{msg_armas.lbl_2mb}"
fileLimitMessage="#{msg_armas['msg_error_exedeelnumero']}"
sizeLimit="100000000" />
</p:column>
<p:column>
<h:outputText value="#{msg_armas.firma_mensaje}" rendered="#{firmarDocumentoController.mensajeGuardar}"/>
<h:outputText value=" #{msg_armas.firma_mensaje2}" style="font-weight: bold;" rendered="#{firmarDocumentoController.mensajeGuardar}"/>
<h:outputText value="#{msg_armas.firma_mensaje3}" rendered="#{firmarDocumentoController.mensajeGuardar}"/>
<h:outputText value="#{msg_armas.firma_mensaje4}" rendered="#{firmarDocumentoController.mensajeNoFirma}"/>
</p:column>
</p:row>
</p:panelGrid>
</p:panelGrid>
<p:panelGrid id="data-content" columns="1" styleClass="m-data-content">
<f:facet name="header">
<h:outputText value="#{msg_general.lbl_firmadoDoc}" />
</f:facet>
<p:panelGrid>
<script src="https://www.java.com/js/deployJava.js"></script>
<script>
var attributes = {code:'com.fp.firma.applet.FirmaApplet.class',
archive:'../../app/appletFirma-2.1.jar,../../app/bcpkix-jdk15on-1.49.jar,../../app/bcmail-jdk15on-1.51.jar,../../app/bcprov-jdk15on-1.49.jar,../../app/bcprov-ext-jdk15on-1.49.jar,../../app/itextpdf-5.5.3.jar',
width:400,
height:200,
mayscript:true,
scriptable:true} ;
var parameters = {fontSize:16, razon:'Documento generado para firma', lugar:'#{firmarDocumentoController.appletLugar}', firma:'#{firmarDocumentoController.appletFirma}', llx:'#{msg_armas.firma_coordenadallx}', lly:'#{msg_armas.firma_coordenadally}', urx:'#{msg_armas.firma_coordenadaurx}', ury:'#{msg_armas.firma_coordenadaury}'};
var version = '1.4' ;
deployJava.runApplet(attributes, parameters, version);
</script>
</p:panelGrid>
</p:panelGrid>
<h:panelGrid columns="7" id="controls" styleClass="m-controls">
<p:commandButton value="#{msg_general.btn_save}" actionListener="#{firmarDocumentoController.saveWithDocumentAlfresco}"
icon="ui-icon-disk" process="@this" update="controls" immediate="true" disabled="#{!empty firmarDocumentoController.btnFlujo}">
</p:commandButton>
<p:commandButton id="idComplete" value="#{msg_armas.btn_enviar}" icon="ui-icon-circle-check" disabled="#{empty firmarDocumentoController.btnFlujo}"
process="@this" action="#{firmarDocumentoController.completarTarea()}" oncomplete="Maia.loadPageUtil();"/>
</h:panelGrid>
</h:form>
</ui:define>
</ui:composition>