[12e6ddf] | 1 | <!DOCTYPE html> |
---|
| 2 | <!-- release v4.1.8, copyright 2014 - 2015 Kartik Visweswaran --> |
---|
| 3 | <html lang="es"> |
---|
| 4 | <head> <!--Inicio del head --> |
---|
| 5 | <meta charset="UTF-8"/> |
---|
| 6 | <link rel="stylesheet" href="css/jquery.Jcrop.css" type="text/css" /> |
---|
| 7 | |
---|
| 8 | <script type="text/javascript" src="js/jquery.min.js"></script> |
---|
| 9 | <script type="text/javascript" src="js/hwcrypto-legacy.js"></script> |
---|
| 10 | <script type="text/javascript" src="js/hwcrypto.js"></script> |
---|
| 11 | <script type="text/javascript" src="js/hex2base.js"></script> |
---|
| 12 | <script type="text/javascript" src="js/forge.min.js"></script> |
---|
| 13 | <script type="text/javascript" src="js/ajaxSetup.js"></script> |
---|
| 14 | <script src="js/jquery.Jcrop.js"></script> |
---|
| 15 | |
---|
| 16 | |
---|
| 17 | <script type="text/javascript" charset="utf-8"> |
---|
| 18 | if (location.protocol != 'https:'){ |
---|
| 19 | location.href = 'https:' + window.location.href.substring(window.location.protocol.length); |
---|
| 20 | }else{ |
---|
| 21 | var urlActiva = "https://"+window.location.hostname; |
---|
| 22 | } |
---|
| 23 | var jcrop_api; |
---|
| 24 | $(document).ready(function() { |
---|
| 25 | $.ajaxSetup({ |
---|
| 26 | error:function(x,e){ |
---|
| 27 | if(x.status==0){ |
---|
| 28 | alert('Está fuera de línea!!\n Por favor chequee su conexión.'); |
---|
| 29 | }else if(x.status==404){ |
---|
| 30 | alert('La URL solicitada no fue encontrada.'); |
---|
| 31 | }else if(x.status==500){ |
---|
| 32 | alert('Error interno de servidor.'); |
---|
| 33 | }else if(e=='parsererror'){ |
---|
| 34 | alert('Error.\nSolicitud de interpretación de cadena JSON inválida.'); |
---|
| 35 | }else if(e=='timeout'){ |
---|
| 36 | alert('Tiempo de espera alcanzado.'); |
---|
| 37 | }else { |
---|
| 38 | alert('Error desconocido.\n'+x.responseText); |
---|
| 39 | } |
---|
| 40 | } |
---|
| 41 | }); |
---|
| 42 | $("#botonEnvia").click(enviaFormulario); |
---|
| 43 | $("#botonCertificadoTarjeta").click(obtieneCertificado); |
---|
| 44 | $("#botonPK12").click(cargaP12); |
---|
| 45 | $("#botonImagen").click(cargaImagen); |
---|
| 46 | $("#botonEstadisticas").click(verificaEstadisticas); |
---|
| 47 | $("#botonSubeVerifica").click(cargaVerifica); |
---|
| 48 | $('#tablaImagen').css("display","none"); |
---|
| 49 | $("input[name=tipoPos]").click(cambioTipoPos) |
---|
| 50 | descargarArchivo = downQuery; |
---|
| 51 | }); |
---|
| 52 | function showCoords(c){ |
---|
| 53 | var alto = parseInt($('#imagenPrevia').attr("height").replace("px","")); |
---|
| 54 | $("#llx").val(c.x); |
---|
| 55 | $("#lly").val(((alto-c.y)-c.h)); |
---|
| 56 | $("#urx").val(c.w); |
---|
| 57 | $("#ury").val(c.h); |
---|
| 58 | }; |
---|
| 59 | |
---|
| 60 | var descargarArchivo; |
---|
| 61 | function ejecutaDescarga(){ |
---|
| 62 | var opciones = new Object(); |
---|
| 63 | opciones.onCompletado = solicitudCompletada; |
---|
| 64 | opciones.onSend = antesEnvioSolicitud; |
---|
| 65 | opciones.onExito = exitoSolicitud; |
---|
| 66 | opciones.onProgreso = muestraProgreso; |
---|
| 67 | opciones.tipoResultado="binary"; |
---|
| 68 | opciones.id="1"; |
---|
| 69 | descargarArchivo.dArchivo($(this).attr("linkDescarga"),opciones); |
---|
| 70 | } |
---|
| 71 | |
---|
| 72 | function muestraProgreso(evt,xhr){ |
---|
| 73 | $("#progresoDescarga").html(evt.lengthComputable+"<br>"); |
---|
| 74 | if (evt.lengthComputable) { |
---|
| 75 | var percentComplete = evt.loaded / evt.total; |
---|
| 76 | $("#progresoDescarga").html(percentComplete.toFixed(2).replace(".",",")+" %"); |
---|
| 77 | }else{ |
---|
| 78 | $("#progresoDescarga").html("Progreso solo<br>"); |
---|
| 79 | } |
---|
| 80 | } |
---|
| 81 | function errorSolicitud(xhr, ajaxOptions, errorArrojado) { |
---|
| 82 | $("#progresoDescarga").append("Error"); |
---|
| 83 | $("#progresoDescarga").append("<br>"); |
---|
| 84 | $("#progresoDescarga").append(xhr.responseText); |
---|
| 85 | $("#progresoDescarga").append("<br>"); |
---|
| 86 | $("#progresoDescarga").append(errorArrojado); |
---|
| 87 | $("#progresoDescarga").append("<br>"); |
---|
| 88 | |
---|
| 89 | } |
---|
| 90 | function antesEnvioSolicitud(evt,opciones) { |
---|
| 91 | console.log("antesEnvioSolicitud") |
---|
| 92 | console.log(opciones.id); |
---|
| 93 | $("#progresoDescarga").html("Iniciando descarga"); |
---|
| 94 | //$("#progresoDescarga").html("antesEnvioSolicitud") |
---|
| 95 | } |
---|
| 96 | function solicitudCompletada(evt,state) { |
---|
| 97 | console.log("solicitudCompletada"); |
---|
| 98 | console.log(evt.opciones.id) |
---|
| 99 | $("#progresoDescarga").html(""); |
---|
| 100 | //$("#progresoDescarga").html("solicitudCompletada"); |
---|
| 101 | } |
---|
| 102 | function exitoSolicitud(data, status, xhr) { |
---|
| 103 | if(data){ |
---|
| 104 | //$("#progresoDescarga"+"B").append("Objetivo: " + xhr.opciones.url + "<br>"); |
---|
| 105 | var nombreArchivo = descargarArchivo.obtieneNombre(xhr); |
---|
| 106 | //$("#progresoDescarga"+"B").append("Archivo: " + nombreArchivo + "<br>"); |
---|
| 107 | var downloadUrl = URL.createObjectURL(data); |
---|
| 108 | if(xhr.opciones.id=="1"){ |
---|
| 109 | var a = document.createElement("a"); |
---|
| 110 | a.href = downloadUrl; |
---|
| 111 | a.download = nombreArchivo; |
---|
| 112 | document.body.appendChild(a); |
---|
| 113 | a.click(); |
---|
| 114 | }/*else{ |
---|
| 115 | var a = document.createElement("img"); |
---|
| 116 | a.src = downloadUrl; |
---|
| 117 | document.body.appendChild(a); |
---|
| 118 | }*/ |
---|
| 119 | } |
---|
| 120 | $("#progresoDescarga"+"B").append("exitoSolicitud 2<br>"); |
---|
| 121 | } |
---|
| 122 | |
---|
| 123 | var certificadoActivo; |
---|
| 124 | var almacenDigitalActivo=false; |
---|
| 125 | function obtieneCertificado(){ |
---|
| 126 | window.hwcrypto.getCertificate({lang: "en"}).then(function(response) { |
---|
| 127 | var cert = response; |
---|
| 128 | certificadoActivo = cert; |
---|
| 129 | console.log("Using certificate:\n" + hexToPem(response.hex)); |
---|
| 130 | console.log("Using certificate(HEX):\n" + response.hex); |
---|
| 131 | if(totalArchivos.length>0){ |
---|
| 132 | $("button[name^='botonFirma-'").attr("disabled",false); |
---|
| 133 | } |
---|
| 134 | }); |
---|
| 135 | } |
---|
| 136 | |
---|
| 137 | var fileIdActivo; |
---|
| 138 | function enviaFormulario(){ |
---|
| 139 | for(var n =0;n<$("#file-sign")[0].files.length;n++){ |
---|
| 140 | var formData = new FormData(); |
---|
| 141 | formData.append("upload", $("#file-sign")[0].files[n]); |
---|
| 142 | //alert(urlActiva+"/Murachi/0.4/archivos/"); |
---|
| 143 | $.ajax({ |
---|
| 144 | url: urlActiva+"/Murachi/0.4/archivos/", |
---|
| 145 | type: "post", |
---|
| 146 | dataType: "json", |
---|
| 147 | data: formData, |
---|
| 148 | xhr: function() { |
---|
| 149 | var myXhr = $.ajaxSettings.xhr(); |
---|
| 150 | if(myXhr.upload){ |
---|
| 151 | myXhr.upload.addEventListener('progress',progressUpload, false); |
---|
| 152 | } |
---|
| 153 | return myXhr; |
---|
| 154 | }, |
---|
| 155 | cache: false, |
---|
| 156 | contentType: false, |
---|
| 157 | processData: false, |
---|
| 158 | headers: {"Authorization":"Basic YWRtaW46YWRtaW4="}, |
---|
| 159 | success: function(response) { |
---|
| 160 | $("#respuesta").html(""); |
---|
| 161 | for(var key in response) { |
---|
| 162 | $("#respuesta").html($("#respuesta").html()+"<br>"+response[key]) |
---|
| 163 | console.log(key); |
---|
| 164 | } |
---|
| 165 | $("input[name=tipoPos]").attr("checked",false); |
---|
| 166 | incluyeArchivo(response); |
---|
| 167 | console.log(response) |
---|
| 168 | if(jcrop_api != null){ |
---|
| 169 | jcrop_api.destroy(); |
---|
| 170 | } |
---|
| 171 | $('#tablaImagen').css("display","none"); |
---|
| 172 | }, |
---|
| 173 | error: function(jqXHR, textStatus, errorThrown){ |
---|
| 174 | console.log('error: ' + textStatus); |
---|
| 175 | //var responseText = jQuery.parseJSON(jqXHR.responseText); |
---|
| 176 | console.log('ajax error function: ' + jqXHR.responseText); |
---|
| 177 | $("#respuesta").html("error function: " + jqXHR.responseText); |
---|
| 178 | } |
---|
| 179 | }) |
---|
| 180 | } |
---|
| 181 | } |
---|
| 182 | function progressUpload(e){ |
---|
| 183 | if(e.lengthComputable){ |
---|
| 184 | var max = e.total; |
---|
| 185 | var current = e.loaded; |
---|
| 186 | |
---|
| 187 | var Percentage = (current * 100)/max; |
---|
| 188 | console.log(Percentage); |
---|
| 189 | |
---|
| 190 | |
---|
| 191 | if(Percentage >= 100) |
---|
| 192 | { |
---|
| 193 | // process completed |
---|
| 194 | $("#progresoCarga").html("100 % (Carga completada)"); |
---|
| 195 | }else{ |
---|
| 196 | $("#progresoCarga").html((Percentage.toFixed(2).replace(".",","))+" %"); |
---|
| 197 | |
---|
| 198 | } |
---|
| 199 | } |
---|
| 200 | } |
---|
| 201 | |
---|
| 202 | function buscaPos(cod){ |
---|
| 203 | var obj = new Array(); |
---|
| 204 | var alto = parseInt($('#imagenPrevia').attr("height").replace("px","")); |
---|
| 205 | var ancho = parseInt($('#imagenPrevia').attr("width").replace("px","")); |
---|
| 206 | var anchoFirma = parseInt($('#urx').val()); |
---|
| 207 | var altoFirma = parseInt($('#ury').val()); |
---|
| 208 | obj["alto"] = altoFirma; |
---|
| 209 | obj["ancho"] = anchoFirma; |
---|
| 210 | if(cod==1){ |
---|
| 211 | obj["x"] = 0; |
---|
| 212 | obj["y"] = (alto-altoFirma); |
---|
| 213 | }else if(cod==2){ |
---|
| 214 | obj["y"] = (alto-altoFirma); |
---|
| 215 | obj["x"] = ((ancho/2)-(anchoFirma/2)); |
---|
| 216 | }else if(cod==3){ |
---|
| 217 | obj["y"] = (alto-altoFirma); |
---|
| 218 | obj["x"] = ((ancho)-anchoFirma); |
---|
| 219 | }else if(cod==4){ |
---|
| 220 | obj["x"] = 0; |
---|
| 221 | obj["y"] = ((alto/2)-(altoFirma/2)); |
---|
| 222 | }else if(cod==5){ |
---|
| 223 | obj["y"] = ((alto/2)-(altoFirma/2)); |
---|
| 224 | obj["x"] = ((ancho/2)-(anchoFirma/2)); |
---|
| 225 | }else if(cod==6){ |
---|
| 226 | obj["y"] = ((alto/2)-(altoFirma/2)); |
---|
| 227 | obj["x"] = (ancho-anchoFirma); |
---|
| 228 | }else if(cod==7){ |
---|
| 229 | obj["x"] = 0; |
---|
| 230 | obj["y"] = 0; |
---|
| 231 | }else if(cod==8){ |
---|
| 232 | obj["y"] = 0; |
---|
| 233 | obj["x"] = ((ancho/2)-(anchoFirma/2)); |
---|
| 234 | }else if(cod==9){ |
---|
| 235 | obj["y"] = 0; |
---|
| 236 | obj["x"] = (ancho-anchoFirma); |
---|
| 237 | } |
---|
| 238 | |
---|
| 239 | return obj; |
---|
| 240 | } |
---|
| 241 | |
---|
| 242 | function cambioTipoPos(){ |
---|
| 243 | if(jcrop_api != null){ |
---|
| 244 | jcrop_api.destroy(); |
---|
| 245 | } |
---|
| 246 | if($(this).val()!=3){ |
---|
| 247 | $('#tablaImagen').css("display","none"); |
---|
| 248 | dimensionesActuales=null; |
---|
| 249 | }else{ |
---|
| 250 | var objArchivo = $("input[name=idArchivo]:checked"); |
---|
| 251 | dimensionesActuales = new Array(); |
---|
| 252 | dimensionesActuales["alto"] = objArchivo.attr("alto"); |
---|
| 253 | dimensionesActuales["ancho"] = objArchivo.attr("ancho"); |
---|
| 254 | dimensionesActuales["paginas"] = objArchivo.attr("paginas"); |
---|
| 255 | |
---|
| 256 | $('#tablaImagen').css("display","block"); |
---|
| 257 | $('#tablaImagen').attr("width",dimensionesActuales["ancho"]+"px"); |
---|
| 258 | $('#tablaImagen').attr("style","border:1px solid #000000"); |
---|
| 259 | $('#imagenPrevia').attr("width",dimensionesActuales["ancho"]+"px"); |
---|
| 260 | $('#imagenPrevia').attr("height",dimensionesActuales["alto"]+"px"); |
---|
| 261 | $('#imagenPrevia').Jcrop({ |
---|
| 262 | onChange: showCoords, |
---|
| 263 | onSelect: showCoords, |
---|
| 264 | bgColor: 'black', |
---|
| 265 | bgOpacity: .4 |
---|
| 266 | },function(){ |
---|
| 267 | jcrop_api = this; |
---|
| 268 | }) |
---|
| 269 | } |
---|
| 270 | } |
---|
| 271 | var dimensionesActuales; |
---|
| 272 | function cambiaArchivo(){ |
---|
| 273 | if(jcrop_api != null){ |
---|
| 274 | jcrop_api.destroy(); |
---|
| 275 | } |
---|
| 276 | $('#tablaImagen').css("display","none"); |
---|
| 277 | |
---|
| 278 | } |
---|
| 279 | var hashtype = "SHA-256"; |
---|
| 280 | var lang = "eng"; |
---|
| 281 | |
---|
| 282 | function procesaIndividual(){ |
---|
| 283 | var cert = certificadoActivo; |
---|
| 284 | /* |
---|
| 285 | var fileId = fileIdActivo; |
---|
| 286 | var fileId = "7778827d-1e20-4e78-a49e-79f7862ec44d"; |
---|
| 287 | */ |
---|
| 288 | //console.log("Using certificate:\n" + hexToPem(response.hex)); |
---|
| 289 | var continua = true; |
---|
| 290 | var mensajeContinua = ""; |
---|
| 291 | var archivoEstimado = $(this).attr("id").replace("botonFirma-",""); |
---|
| 292 | if($("input[name=fimaTarjeta]:checked").val()== undefined){ |
---|
| 293 | if($("input[name=idArchivo]:checked").val()== archivoEstimado){ |
---|
| 294 | if(!cert && !almacenDigitalActivo){ |
---|
| 295 | alert("Debe seleccionar el certificado para firmar"); |
---|
| 296 | //console.log("cert: "+ cert.hex); |
---|
| 297 | }else{ |
---|
| 298 | var firmaVisible = false; |
---|
| 299 | if($("input[name=firmaVisible]:checked").val()==1){ |
---|
| 300 | firmaVisible = true; |
---|
| 301 | } |
---|
| 302 | if($("input[name=idArchivo]:checked").val()==undefined){ |
---|
| 303 | alert("Debe seleccionar primero un archivo"); |
---|
| 304 | }else{ |
---|
| 305 | |
---|
| 306 | if($("input[name=tipoPos]:checked").val()==undefined || $("input[name=tipoPos]:checked").val()==1){ |
---|
| 307 | var alto = parseInt($('#imagenPrevia').attr("height").replace("px","")); |
---|
| 308 | var ancho = parseInt($('#imagenPrevia').attr("width").replace("px","")); |
---|
| 309 | |
---|
| 310 | $("#llx").val(0); |
---|
| 311 | $("#lly").val(alto-50); |
---|
| 312 | $("#urx").val(100); |
---|
| 313 | $("#ury").val(50); |
---|
| 314 | |
---|
| 315 | }else if($("input[name=tipoPos]:checked").val()==2){ |
---|
| 316 | if($("input[name=tipoPos]:checked").val()==undefined){ |
---|
| 317 | continua = false; |
---|
| 318 | mensajeContinua = "Debe seleccionar la posición de la firma"; |
---|
| 319 | }else{ |
---|
| 320 | var pos = buscaPos($("input[name=posFijo]:checked").val()); |
---|
| 321 | $("#llx").val(pos["x"]); |
---|
| 322 | $("#lly").val(pos["y"]); |
---|
| 323 | $("#urx").val(pos["ancho"]); |
---|
| 324 | $("#ury").val(pos["alto"]); |
---|
| 325 | } |
---|
| 326 | }else if($("input[name=tipoPos]:checked").val()==3){ |
---|
| 327 | var api = jcrop_api; |
---|
| 328 | //alert(api.tellSelect().x+"|"+api.tellSelect().y+"|"+($('#imagenPrevia').attr("width"))+"|"+($('#imagenPrevia').attr("height")-api.tellSelect().y)+"|"+api.tellSelect().w+"|"+api.tellSelect().h) |
---|
| 329 | var alto = parseInt($('#imagenPrevia').attr("height").replace("px","")); |
---|
| 330 | $("#llx").val(api.tellSelect().x); |
---|
| 331 | $("#lly").val(((alto-api.tellSelect().y)-api.tellSelect().h)); |
---|
| 332 | $("#urx").val(api.tellSelect().w); |
---|
| 333 | $("#ury").val(api.tellSelect().h); |
---|
| 334 | } |
---|
| 335 | if(!cert){ |
---|
| 336 | var certificado = ""; |
---|
| 337 | }else{ |
---|
| 338 | certificado = cert.hex; |
---|
| 339 | } |
---|
| 340 | var muestraImagen = false; |
---|
| 341 | if($("input[name=muestraImagen]:checked").val()==1){ |
---|
| 342 | muestraImagen = true; |
---|
| 343 | } |
---|
| 344 | var muestraImagenSola = false; |
---|
| 345 | if($("input[name=muestraImagenSola]:checked").val()==1){ |
---|
| 346 | muestraImagenSola = true; |
---|
| 347 | } |
---|
| 348 | var ancho = 100; |
---|
| 349 | if(!isNaN(parseInt($("#urx").val()))){ |
---|
| 350 | ancho = parseInt($("#urx").val()); |
---|
| 351 | } |
---|
| 352 | var alto = 100; |
---|
| 353 | if(!isNaN(parseInt($("#ury").val()))){ |
---|
| 354 | alto = parseInt($("#ury").val()); |
---|
| 355 | } |
---|
| 356 | var posX = 100; |
---|
| 357 | if(!isNaN(parseInt($("#llx").val()))){ |
---|
| 358 | posX = parseInt($("#llx").val()); |
---|
| 359 | } |
---|
| 360 | var posY = 100; |
---|
| 361 | if(!isNaN(parseInt($("#lly").val()))){ |
---|
| 362 | posY = parseInt($("#lly").val()); |
---|
| 363 | } |
---|
| 364 | var urlFirma = urlActiva+"/Murachi/0.4/archivos/pdfsTest"; |
---|
| 365 | var firmaPK12 = false; |
---|
| 366 | var clavePCKS12 =""; |
---|
| 367 | var imagenAdjunta = ""; |
---|
| 368 | if(imagenId!=null){ |
---|
| 369 | imagenAdjunta = imagenId; |
---|
| 370 | } |
---|
| 371 | if($("input[name=firmaTarjeta]:checked").val()==2){ |
---|
| 372 | if($("#clavePCKS12").val()!=""){ |
---|
| 373 | urlFirma = urlActiva+"/Murachi/0.4/archivos/pdfsPk"; |
---|
| 374 | firmaPK12 = true; |
---|
| 375 | clavePCKS12 = $("#clavePCKS12").val(); |
---|
| 376 | }else{ |
---|
| 377 | continua = false; |
---|
| 378 | mensajeContinua = "Debe ingresar la clave del almacén digital para poder continuar" |
---|
| 379 | } |
---|
| 380 | } |
---|
| 381 | if(continua){ |
---|
| 382 | //alert(urlFirma) |
---|
| 383 | var fileId = $("input[name=idArchivo]:checked").val(); |
---|
| 384 | var parameters = JSON.stringify({ |
---|
| 385 | "fileId":fileId, |
---|
| 386 | "certificate":certificado, |
---|
| 387 | "reason":$("#razon").val(), |
---|
| 388 | "location":$("#lugar").val(), |
---|
| 389 | "contact":$("#contacto").val(), |
---|
| 390 | "pk12":firmaPK12, |
---|
| 391 | "clavePCKS12":clavePCKS12, |
---|
| 392 | "almacenPCKS12":almacenId, |
---|
| 393 | "signatureVisible":firmaVisible, |
---|
| 394 | "lly":posY, |
---|
| 395 | "llx":posX, |
---|
| 396 | "ury":posY+alto, |
---|
| 397 | "urx":posX+ancho, |
---|
| 398 | "muestraImagen":muestraImagen, |
---|
| 399 | "muestraImagenSola":muestraImagenSola, |
---|
| 400 | "imagen":imagenAdjunta |
---|
| 401 | }); |
---|
| 402 | |
---|
| 403 | // ahora llamar al ajax de obtener la resena del pdf |
---|
| 404 | $.ajax({ |
---|
| 405 | url: urlFirma, |
---|
| 406 | type: "post", |
---|
| 407 | dataType: "json", |
---|
| 408 | data: parameters, |
---|
| 409 | contentType: "application/json", |
---|
| 410 | headers: {"Authorization":"Basic YWRtaW46YWRtaW4="}, |
---|
| 411 | success: function(data, textStatus, jqXHR){ |
---|
| 412 | for(var key in data) { |
---|
| 413 | $("#respuesta").html($("#respuesta").html()+"<br>"+data[key]) |
---|
| 414 | console.log(key); |
---|
| 415 | } |
---|
| 416 | console.log(data) |
---|
| 417 | $("#botonFirma-"+archivoEstimado).attr("disabled",true); |
---|
| 418 | if(!almacenDigitalActivo){ |
---|
| 419 | |
---|
| 420 | }else{ |
---|
| 421 | var linkDescarga = "<a href=\""+urlActiva+"/Murachi/0.4/archivos/descargas/" + data['fileId'] +"\">descargar archivo firmado</a>"; |
---|
| 422 | $("#respuesta").html($("#respuesta").html()+"<br>"+linkDescarga); |
---|
| 423 | idFileDescargaActual = data['fileId']; |
---|
| 424 | console.log(data); |
---|
| 425 | $("#botonDescarga-"+archivoEstimado).attr("linkDescarga",urlActiva+"/Murachi/0.4/archivos/descargas/" + data['fileId']); |
---|
| 426 | $("#botonDescarga-"+archivoEstimado).attr("disabled",false); |
---|
| 427 | } |
---|
| 428 | |
---|
| 429 | |
---|
| 430 | }, function(err) { |
---|
| 431 | var error; |
---|
| 432 | if(err == "Error: user_cancel") { |
---|
| 433 | console.log("getCertificate() failed: El usuario cancelo la operación" ); |
---|
| 434 | error = "El usuario cancelo la operación"; |
---|
| 435 | } |
---|
| 436 | else if(err == "Error: no_certificates") { |
---|
| 437 | console.log("getCertificate() failed: No hay certificado disponible") ; |
---|
| 438 | error = "No hay certificado disponible"; |
---|
| 439 | } |
---|
| 440 | else if(err == "Error: no_implementation") { |
---|
| 441 | console.log("getCertificate() failed: No hay soporte para el manejo del certificado"); |
---|
| 442 | error = "No hay soporte para el manejo del certificado"; |
---|
| 443 | } |
---|
| 444 | $("#respuesta").html("getCertificate() failed: " + error); |
---|
| 445 | } |
---|
| 446 | }); |
---|
| 447 | }else{ |
---|
| 448 | alert(mensajeContinua); |
---|
| 449 | } |
---|
| 450 | } |
---|
| 451 | } |
---|
| 452 | }else{ |
---|
| 453 | alert("Debe seleccionar este archivo para poder firmarlo") |
---|
| 454 | } |
---|
| 455 | }else{ |
---|
| 456 | alert("Debe seleccionar un método de firma") |
---|
| 457 | } |
---|
| 458 | } |
---|
| 459 | function reemplazaCadena(busca,cambia,texto){ |
---|
| 460 | while(texto.indexOf(busca)>-1){ |
---|
| 461 | texto = texto.replace(busca,cambia); |
---|
| 462 | } |
---|
| 463 | return texto; |
---|
| 464 | } |
---|
| 465 | var totalArchivos = new Array(); |
---|
| 466 | function incluyeArchivo(response){ |
---|
| 467 | var idArchivo = response["fileId"]; |
---|
| 468 | totalArchivos.push(idArchivo); |
---|
| 469 | var archivoNuevo = '<tr id="archivo-'+idArchivo+'">'+$("#archivoPrototipo").html()+'</tr>'; |
---|
| 470 | archivoNuevo = reemplazaCadena('/-idArchivo-/',idArchivo,archivoNuevo); |
---|
| 471 | archivoNuevo = reemplazaCadena('/-ancho-/',response["ancho"],archivoNuevo); |
---|
| 472 | archivoNuevo = reemplazaCadena('/-alto-/',response["alto"],archivoNuevo); |
---|
| 473 | archivoNuevo = reemplazaCadena('/-paginas-/',response["paginas"],archivoNuevo); |
---|
| 474 | archivoNuevo = reemplazaCadena('/-valorArchivo-/',idArchivo,archivoNuevo); |
---|
| 475 | archivoNuevo = reemplazaCadena('/-valorRadioArchivo-/',idArchivo,archivoNuevo); |
---|
| 476 | //archivoNuevo = reemplazaCadena('"montoUnitarioArticulo-"','"montoUnitarioArticulo-'+indice+'"',archivoNuevo); |
---|
| 477 | //archivoNuevo = reemplazaCadena('"montoTotalArticulo-"','"montoTotalArticulo-'+indice+'"',archivoNuevo); |
---|
| 478 | //archivoNuevo = reemplazaCadena('"cantidadArticulo-n-oferta"','"cantidadArticulo-'+indice+'-oferta"',archivoNuevo); |
---|
| 479 | //archivoNuevo = reemplazaCadena('"montoUnitarioArticulo-n-oferta"','"montoUnitarioArticulo-'+indice+'-oferta"',archivoNuevo); |
---|
| 480 | //archivoNuevo = reemplazaCadena('"montoTotalArticulo-n-oferta"','"montoTotalArticulo-'+indice+'-oferta"',archivoNuevo); |
---|
| 481 | //archivoNuevo = reemplazaCadena('"botonEliminaArticulo-"','"botonEliminaArticulo-'+indice+'"',archivoNuevo); |
---|
| 482 | //archivoNuevo = reemplazaCadena('"marcaArticulo-"','"marcaArticulo-'+indice+'"',archivoNuevo); |
---|
| 483 | //archivoNuevo = reemplazaCadena('"exoneraArticulo-"','"exoneraArticulo-'+indice+'"',archivoNuevo); |
---|
| 484 | |
---|
| 485 | //$("#tablaArticulos").append(archivoNuevo); |
---|
| 486 | $(archivoNuevo).insertBefore("#totalArchivos"); |
---|
| 487 | $("input[name=idArchivo]").unbind('click'); |
---|
| 488 | $("input[name=idArchivo]").click(cambiaArchivo); |
---|
| 489 | $("#botonFirma-"+idArchivo).click(procesaIndividual); |
---|
| 490 | $("#botonDescarga-"+idArchivo).click(ejecutaDescarga); |
---|
| 491 | var activo = false; |
---|
| 492 | if(!certificadoActivo && !almacenDigitalActivo){ |
---|
| 493 | activo = true; |
---|
| 494 | } |
---|
| 495 | $("#botonFirma-"+idArchivo).attr("disabled",activo); |
---|
| 496 | $("#botonDescarga-"+idArchivo).attr("disabled",true); |
---|
| 497 | $("#sinArchivos").css("display","none"); |
---|
| 498 | $("#archivo-"+idArchivo).css("display","block"); |
---|
| 499 | $("#cantArchivos").html(totalArchivos.length+" Archivos por firma") |
---|
| 500 | } |
---|
| 501 | var almacenId = ""; |
---|
| 502 | function cargaP12(){ |
---|
| 503 | if($("#p12")[0].files.length>0){ |
---|
| 504 | var formData = new FormData(); |
---|
| 505 | formData.append("upload", $("#p12")[0].files[0]); |
---|
| 506 | $.ajax({ |
---|
| 507 | url: urlActiva+"/Murachi/0.4/archivos/p12", |
---|
| 508 | type: "post", |
---|
| 509 | dataType: "json", |
---|
| 510 | data: formData, |
---|
| 511 | xhr: function() { |
---|
| 512 | var myXhr = $.ajaxSettings.xhr(); |
---|
| 513 | if(myXhr.upload){ |
---|
| 514 | myXhr.upload.addEventListener('progress',progressUpload, false); |
---|
| 515 | } |
---|
| 516 | return myXhr; |
---|
| 517 | }, |
---|
| 518 | cache: false, |
---|
| 519 | contentType: false, |
---|
| 520 | processData: false, |
---|
| 521 | headers: {"Authorization":"Basic YWRtaW46YWRtaW4="}, |
---|
| 522 | success: function(response) { |
---|
| 523 | $("#respuesta").html(""); |
---|
| 524 | for(var key in response) { |
---|
| 525 | $("#respuesta").html($("#respuesta").html()+"<br>"+response[key]) |
---|
| 526 | console.log(key); |
---|
| 527 | } |
---|
| 528 | almacenDigitalActivo = true; |
---|
| 529 | almacenId = response["fileId"]; |
---|
| 530 | $("#mensajeP12").html("Archivo almacen digital PCKS12 cargado") |
---|
| 531 | if(totalArchivos.length>0){ |
---|
| 532 | $("button[name^='botonFirma-'").attr("disabled",false); |
---|
| 533 | } |
---|
| 534 | console.log(response) |
---|
| 535 | |
---|
| 536 | }, |
---|
| 537 | error: function(jqXHR, textStatus, errorThrown){ |
---|
| 538 | console.log('error: ' + textStatus); |
---|
| 539 | //var responseText = jQuery.parseJSON(jqXHR.responseText); |
---|
| 540 | console.log('ajax error function: ' + jqXHR.responseText); |
---|
| 541 | $("#respuesta").html("error function: " + jqXHR.responseText); |
---|
| 542 | } |
---|
| 543 | }) |
---|
| 544 | }else{ |
---|
| 545 | alert("Debe seleccionar un almacén digital de firma primero") |
---|
| 546 | } |
---|
| 547 | } |
---|
| 548 | var imagenActiva = false; |
---|
| 549 | var imagenId = ""; |
---|
| 550 | function cargaImagen(){ |
---|
| 551 | if($("#imagen")[0].files.length>0){ |
---|
| 552 | var formData = new FormData(); |
---|
| 553 | formData.append("upload", $("#imagen")[0].files[0]); |
---|
| 554 | $.ajax({ |
---|
| 555 | url: urlActiva+"/Murachi/0.4/archivos/imagenAdjunta", |
---|
| 556 | type: "post", |
---|
| 557 | dataType: "json", |
---|
| 558 | data: formData, |
---|
| 559 | xhr: function() { |
---|
| 560 | var myXhr = $.ajaxSettings.xhr(); |
---|
| 561 | if(myXhr.upload){ |
---|
| 562 | myXhr.upload.addEventListener('progress',progressUpload, false); |
---|
| 563 | } |
---|
| 564 | return myXhr; |
---|
| 565 | }, |
---|
| 566 | cache: false, |
---|
| 567 | contentType: false, |
---|
| 568 | processData: false, |
---|
| 569 | headers: {"Authorization":"Basic YWRtaW46YWRtaW4="}, |
---|
| 570 | success: function(response) { |
---|
| 571 | $("#respuesta").html(""); |
---|
| 572 | for(var key in response) { |
---|
| 573 | $("#respuesta").html($("#respuesta").html()+"<br>"+response[key]) |
---|
| 574 | console.log(key); |
---|
| 575 | } |
---|
| 576 | imagenActiva = true; |
---|
| 577 | imagenId = response["fileId"]; |
---|
| 578 | $("#mensajeImagen").html("Archivo imagen cargado") |
---|
| 579 | console.log(response) |
---|
| 580 | |
---|
| 581 | }, |
---|
| 582 | error: function(jqXHR, textStatus, errorThrown){ |
---|
| 583 | console.log('error: ' + textStatus); |
---|
| 584 | //var responseText = jQuery.parseJSON(jqXHR.responseText); |
---|
| 585 | console.log('ajax error function: ' + jqXHR.responseText); |
---|
| 586 | $("#respuesta").html("error function: " + jqXHR.responseText); |
---|
| 587 | } |
---|
| 588 | }) |
---|
| 589 | }else{ |
---|
| 590 | alert("Debe seleccionar un archivo digital primero") |
---|
| 591 | } |
---|
| 592 | } |
---|
| 593 | |
---|
| 594 | function cargaVerifica(){ |
---|
| 595 | if($("#archivoVerifica")[0].files.length>0){ |
---|
| 596 | var formData = new FormData(); |
---|
| 597 | formData.append("upload", $("#archivoVerifica")[0].files[0]); |
---|
| 598 | $.ajax({ |
---|
| 599 | url: urlActiva+"/Murachi/0.4/archivos/", |
---|
| 600 | type: "post", |
---|
| 601 | dataType: "json", |
---|
| 602 | data: formData, |
---|
| 603 | xhr: function() { |
---|
| 604 | var myXhr = $.ajaxSettings.xhr(); |
---|
| 605 | if(myXhr.upload){ |
---|
| 606 | myXhr.upload.addEventListener('progress',progressVerifica, false); |
---|
| 607 | } |
---|
| 608 | return myXhr; |
---|
| 609 | }, |
---|
| 610 | cache: false, |
---|
| 611 | contentType: false, |
---|
| 612 | processData: false, |
---|
| 613 | headers: {"Authorization":"Basic YWRtaW46YWRtaW4="}, |
---|
| 614 | success: function(response) { |
---|
| 615 | $("#mensajeVerifica").html("Archivo subido correctamente"); |
---|
| 616 | for(var key in response) { |
---|
| 617 | $("#mensajeVerifica").html($("#mensajeVerifica").html()+"<br>"+response[key]) |
---|
| 618 | console.log(key); |
---|
| 619 | } |
---|
| 620 | console.log(response) |
---|
| 621 | |
---|
| 622 | }, |
---|
| 623 | error: function(jqXHR, textStatus, errorThrown){ |
---|
| 624 | console.log('error: ' + textStatus); |
---|
| 625 | //var responseText = jQuery.parseJSON(jqXHR.responseText); |
---|
| 626 | console.log('ajax error function: ' + jqXHR.responseText); |
---|
| 627 | $("#respuesta").html("error function: " + jqXHR.responseText); |
---|
| 628 | } |
---|
| 629 | }) |
---|
| 630 | }else{ |
---|
| 631 | alert("Debe seleccionar un archivo para verificar primero") |
---|
| 632 | } |
---|
| 633 | } |
---|
| 634 | |
---|
| 635 | function progressVerifica(e){ |
---|
| 636 | if(e.lengthComputable){ |
---|
| 637 | var max = e.total; |
---|
| 638 | var current = e.loaded; |
---|
| 639 | |
---|
| 640 | var Percentage = (current * 100)/max; |
---|
| 641 | console.log(Percentage); |
---|
| 642 | |
---|
| 643 | |
---|
| 644 | if(Percentage >= 100) |
---|
| 645 | { |
---|
| 646 | // process completed |
---|
| 647 | $("#progresoVerifica").html("100 % (Carga completada)"); |
---|
| 648 | }else{ |
---|
| 649 | $("#progresoVerifica").html((Percentage.toFixed(2).replace(".",","))+" %"); |
---|
| 650 | |
---|
| 651 | } |
---|
| 652 | } |
---|
| 653 | } |
---|
| 654 | |
---|
| 655 | function verificaEstadisticas(){ |
---|
| 656 | $.ajax({ |
---|
| 657 | url: urlActiva+"/Murachi/0.4/archivos/estadisticas", |
---|
| 658 | type: "get", |
---|
| 659 | dataType: "json", |
---|
| 660 | xhr: function() { |
---|
| 661 | var myXhr = $.ajaxSettings.xhr(); |
---|
| 662 | if(myXhr.upload){ |
---|
| 663 | myXhr.upload.addEventListener('progress',progressUpload, false); |
---|
| 664 | } |
---|
| 665 | return myXhr; |
---|
| 666 | }, |
---|
| 667 | cache: false, |
---|
| 668 | contentType: false, |
---|
| 669 | processData: false, |
---|
| 670 | headers: {"Authorization":"Basic YWRtaW46YWRtaW4="}, |
---|
| 671 | success: function(response) { |
---|
| 672 | $("#respuesta").html(""); |
---|
| 673 | for(var key in response) { |
---|
| 674 | $("#respuesta").html($("#respuesta").html()+"<br>"+response[key]) |
---|
| 675 | console.log(key); |
---|
| 676 | } |
---|
| 677 | console.log(response) |
---|
| 678 | |
---|
| 679 | }, |
---|
| 680 | error: function(jqXHR, textStatus, errorThrown){ |
---|
| 681 | console.log('error: ' + textStatus); |
---|
| 682 | //var responseText = jQuery.parseJSON(jqXHR.responseText); |
---|
| 683 | console.log('ajax error function: ' + jqXHR.responseText); |
---|
| 684 | $("#respuesta").html("error function: " + jqXHR.responseText); |
---|
| 685 | } |
---|
| 686 | }) |
---|
| 687 | } |
---|
| 688 | </script> |
---|
| 689 | |
---|
| 690 | </head> |
---|
| 691 | |
---|
| 692 | |
---|
| 693 | <body> |
---|
| 694 | <table width="1200" border="0" cellspacing="2" cellpadding="5" id="tablaArticulos" align="center"> |
---|
| 695 | <tr> |
---|
| 696 | <td colspan="4" style="text-align:center;">SELECCIONE UN ARCHIVO PARA COLOCARLO</td> |
---|
| 697 | </tr> |
---|
| 698 | <tr> |
---|
| 699 | <td colspan="4" style="text-align:left;"><input id="file-sign" type="file" data-min-file-count="1" name="upload" multiple ></td> |
---|
| 700 | </tr> |
---|
| 701 | <tr> |
---|
| 702 | <td colspan="4" style="text-align:left;"><button type="button" class="button" name="botonEnvia" id="botonEnvia">Cargar archivos</button></td> |
---|
| 703 | </tr> |
---|
| 704 | <tr> |
---|
| 705 | <td colspan="4" style="text-align:left;" id="progresoCarga"> </td> |
---|
| 706 | </tr> |
---|
| 707 | <tr> |
---|
| 708 | <td colspan="4" style="text-align:left;" id="progresoDescarga"> </td> |
---|
| 709 | </tr> |
---|
| 710 | |
---|
| 711 | <tr> |
---|
| 712 | <td colspan="4" style="text-align:center;">ARCHIVOS INCLUIDOS PARA LA FIRMA</td> |
---|
| 713 | </tr> |
---|
| 714 | <td colspan="4" id="sinArchivos" align="center" valign="middle" height="40"> |
---|
| 715 | <strong>No se han ingresado items aún</strong> |
---|
| 716 | </td> |
---|
| 717 | <tr id="archivoPrototipo" style="display:none;"> |
---|
| 718 | <td style="text-align:left;" width="20"><input type="hidden" value="/-valorArchivo-/" id="/-idArchivo-/" name="/-idArchivo-/"/><input type="radio" id="idArchivo" name="idArchivo" value="/-valorRadioArchivo-/" ancho="/-ancho-/" alto="/-alto-/" paginas="/-paginas-/"/></td> |
---|
| 719 | <td style="text-align:left;" width="480">/-valorArchivo-/</td> |
---|
| 720 | <td style="text-align:left;" width="150"><button type="button" class="button" name="botonFirma-/-idArchivo-/" id="botonFirma-/-idArchivo-/" disabled>Firma Archivo</button></td> |
---|
| 721 | <td style="text-align:left;" width="180"><button type="button" class="button" name="botonDescarga-/-idArchivo-/" id="botonDescarga-/-idArchivo-/" disabled>Descarga Archivo</button></td> |
---|
| 722 | </tr> |
---|
| 723 | <tr id="totalArchivos"> |
---|
| 724 | <td colspan="4" style="text-align:center;" id="cantArchivos"> </td> |
---|
| 725 | </tr> |
---|
| 726 | <tr> |
---|
| 727 | <td colspan="4" style="text-align:center;"> |
---|
| 728 | <table width="1200" border="0" cellspacing="2" cellpadding="5" align="center"> |
---|
| 729 | <tr> |
---|
| 730 | <td style="text-align:left;">Razon: <input type="text" value="" id="razon" name="razon"/></td> |
---|
| 731 | <td style="text-align:left;">Lugar: <input type="text" value="" id="lugar" name="lugar"/></td> |
---|
| 732 | <td style="text-align:left;">Contacto: <input type="text" value="" id="contacto" name="contacto"/></td> |
---|
| 733 | </tr> |
---|
| 734 | </table> |
---|
| 735 | </td> |
---|
| 736 | </tr> |
---|
| 737 | |
---|
| 738 | <tr> |
---|
| 739 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 740 | <input type="radio" id="firmaTarjeta" name="firmaTarjeta" value="1"/>Se firmará con tarjeta Smartcard |
---|
| 741 | </td> |
---|
| 742 | </tr> |
---|
| 743 | <tr> |
---|
| 744 | <td colspan="4" style="text-align:center;"> |
---|
| 745 | FIRMA CON TARJETA |
---|
| 746 | </td> |
---|
| 747 | </tr> |
---|
| 748 | |
---|
| 749 | <tr> |
---|
| 750 | <td colspan="4" style="text-align:center;"> |
---|
| 751 | <button type="button" class="button" name="botonCertificadoTarjeta" id="botonCertificadoTarjeta">Obtiene Certificado desde Tarjeta</button> |
---|
| 752 | </td> |
---|
| 753 | </tr> |
---|
| 754 | <tr> |
---|
| 755 | <td colspan="4" style="text-align:center;"> |
---|
| 756 | FIRMA CON CERTIFICADO DIGITAL (.P12) |
---|
| 757 | </td> |
---|
| 758 | </tr> |
---|
| 759 | <tr> |
---|
| 760 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 761 | <input type="radio" id="firmaTarjeta" name="firmaTarjeta" value="2" checked/>Se firmará con almacén digital |
---|
| 762 | </td> |
---|
| 763 | </tr> |
---|
| 764 | <tr> |
---|
| 765 | <td colspan="4" style="text-align:left;"> |
---|
| 766 | <input id="p12" type="file" data-min-file-count="1" name="p12"> |
---|
| 767 | </td> |
---|
| 768 | </tr> |
---|
| 769 | <tr> |
---|
| 770 | <td colspan="4" style="text-align:center;" id="mensajeP12"> |
---|
| 771 | |
---|
| 772 | </td> |
---|
| 773 | </tr> |
---|
| 774 | <tr> |
---|
| 775 | <td style="text-align:left;" colspan="2" width="500"> |
---|
| 776 | CLAVE DEL ALMACEN: <input type="password" value="" id="clavePCKS12" name="clavePCKS12"/> |
---|
| 777 | </td> |
---|
| 778 | <td style="text-align:left;" width="150"> </td> |
---|
| 779 | <td style="text-align:left;" width="150"> </td> |
---|
| 780 | <td style="text-align:left;" width="150"> </td> |
---|
| 781 | </tr> |
---|
| 782 | |
---|
| 783 | <tr> |
---|
| 784 | <td colspan="4" style="text-align:center;"> |
---|
| 785 | <button type="button" class="button" name="botonPK12" id="botonPK12">Carga PKCS 12</button> |
---|
| 786 | </td> |
---|
| 787 | </tr> |
---|
| 788 | |
---|
| 789 | <tr> |
---|
| 790 | <td colspan="4" style="text-align:center;"> |
---|
| 791 | |
---|
| 792 | </td> |
---|
| 793 | </tr> |
---|
| 794 | <tr> |
---|
| 795 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 796 | <input type="radio" id="firmaVisible" name="firmaVisible" value="1" checked/>Firma Visible |
---|
| 797 | </td> |
---|
| 798 | </tr> |
---|
| 799 | <tr> |
---|
| 800 | <td colspan="4" style="text-align:center;"> |
---|
| 801 | |
---|
| 802 | <table width="1200" border="0" cellspacing="2" cellpadding="5" align="center"> |
---|
| 803 | <tr> |
---|
| 804 | <td style="text-align:left;" colspan="300" width="500">Pos X<br><input type="text" value="0" id="llx" name="llx"/></td> |
---|
| 805 | <td style="text-align:left;" width="300">Pos Y<br><input type="text" value="0" id="lly" name="lly"/></td> |
---|
| 806 | <td style="text-align:left;" width="300">Ancho<br><input type="text" value="100" id="urx" name="urx"/></td> |
---|
| 807 | <td style="text-align:left;" width="300">Alto<br><input type="text" value="50" id="ury" name="ury"/></td> |
---|
| 808 | </tr> |
---|
| 809 | </table> |
---|
| 810 | </td> |
---|
| 811 | </tr> |
---|
| 812 | <tr> |
---|
| 813 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 814 | <input type="radio" id="firmaVisible" name="firmaVisible" value="2"/>Firma no Visible |
---|
| 815 | </td> |
---|
| 816 | </tr> |
---|
| 817 | |
---|
| 818 | |
---|
| 819 | <tr> |
---|
| 820 | <td colspan="4" style="text-align:center;"> |
---|
| 821 | IMÁGEN ADJUNTA AL MENSAJE |
---|
| 822 | </td> |
---|
| 823 | </tr> |
---|
| 824 | |
---|
| 825 | <tr> |
---|
| 826 | <td colspan="4" style="text-align:left;"><input id="imagen" name="imagen" type="file" data-min-file-count="1" name="min"></td> |
---|
| 827 | </tr> |
---|
| 828 | <tr> |
---|
| 829 | <td colspan="4" style="text-align:center;" id="mensajeImagen"> |
---|
| 830 | |
---|
| 831 | </td> |
---|
| 832 | </tr> |
---|
| 833 | <tr> |
---|
| 834 | <td colspan="4" style="text-align:center;"> |
---|
| 835 | <button type="button" class="button" name="botonImagen" id="botonImagen">Carga Imágen</button> |
---|
| 836 | </td> |
---|
| 837 | </tr> |
---|
| 838 | |
---|
| 839 | <tr> |
---|
| 840 | <td colspan="4" style="text-align:center;"> |
---|
| 841 | CARACTERÍSTICAS A MOSTRAR |
---|
| 842 | </td> |
---|
| 843 | </tr> |
---|
| 844 | <tr> |
---|
| 845 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 846 | <input type="radio" id="muestraImagen" name="muestraImagen" value="1"/>Muestra Imágen |
---|
| 847 | </td> |
---|
| 848 | </tr> |
---|
| 849 | <tr> |
---|
| 850 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 851 | <input type="radio" id="muestraImagen" name="muestraImagen" value="2" checked/>No muestra imágen |
---|
| 852 | </td> |
---|
| 853 | </tr> |
---|
| 854 | |
---|
| 855 | <tr> |
---|
| 856 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 857 | <input type="radio" id="muestraImagenSola" name="muestraImagenSola" value="1"/>Muestra imagen sola |
---|
| 858 | </td> |
---|
| 859 | </tr> |
---|
| 860 | <tr> |
---|
| 861 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 862 | <input type="radio" id="muestraImagenSola" name="muestraImagenSola" value="2" checked/>No muestra imagen sola |
---|
| 863 | </td> |
---|
| 864 | </tr> |
---|
| 865 | <tr> |
---|
| 866 | <td colspan="4" style="text-align:center;"> |
---|
| 867 | POSICIONAMIENTO |
---|
| 868 | </td> |
---|
| 869 | </tr> |
---|
| 870 | <tr> |
---|
| 871 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 872 | <input type="radio" id="tipoPos" name="tipoPos" value="1" checked/>Por defecto |
---|
| 873 | </td> |
---|
| 874 | </tr> |
---|
| 875 | <tr> |
---|
| 876 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 877 | <input type="radio" id="tipoPos" name="tipoPos" value="2"/>Predeterminado |
---|
| 878 | </td> |
---|
| 879 | </tr> |
---|
| 880 | |
---|
| 881 | <tr> |
---|
| 882 | <td colspan="4" style="text-align:center;"> |
---|
| 883 | <table width="120" border="0" cellspacing="2" cellpadding="5" align="center"> |
---|
| 884 | <tr> |
---|
| 885 | <td style="text-align:center;" width="40"> |
---|
| 886 | <input type="radio" id="posFijo" name="posFijo" value="1"/> |
---|
| 887 | </td> |
---|
| 888 | <td style="text-align:center;" width="40"> |
---|
| 889 | <input type="radio" id="posFijo" name="posFijo" value="2"/> |
---|
| 890 | </td> |
---|
| 891 | <td style="text-align:center;" width="40"> |
---|
| 892 | <input type="radio" id="posFijo" name="posFijo" value="3"/> |
---|
| 893 | </td> |
---|
| 894 | </tr> |
---|
| 895 | <tr> |
---|
| 896 | <td style="text-align:center;" width="40"> |
---|
| 897 | <input type="radio" id="posFijo" name="posFijo" value="4"/> |
---|
| 898 | </td> |
---|
| 899 | <td style="text-align:center;" width="40"> |
---|
| 900 | <input type="radio" id="posFijo" name="posFijo" value="5"/> |
---|
| 901 | </td> |
---|
| 902 | <td style="text-align:center;" width="40"> |
---|
| 903 | <input type="radio" id="posFijo" name="posFijo" value="6"/> |
---|
| 904 | </td> |
---|
| 905 | </tr> |
---|
| 906 | <tr> |
---|
| 907 | <td style="text-align:center;" width="40"> |
---|
| 908 | <input type="radio" id="posFijo" name="posFijo" value="7"/> |
---|
| 909 | </td> |
---|
| 910 | <td style="text-align:center;" width="40"> |
---|
| 911 | <input type="radio" id="posFijo" name="posFijo" value="8"/> |
---|
| 912 | </td> |
---|
| 913 | <td style="text-align:center;" width="40"> |
---|
| 914 | <input type="radio" id="posFijo" name="posFijo" value="9"/> |
---|
| 915 | </td> |
---|
| 916 | </tr> |
---|
| 917 | </table> |
---|
| 918 | </td> |
---|
| 919 | </tr> |
---|
| 920 | <tr> |
---|
| 921 | <td style="text-align:left;" width="20" colspan="4"> |
---|
| 922 | <input type="radio" id="tipoPos" name="tipoPos" value="3"/>Personalizado |
---|
| 923 | </td> |
---|
| 924 | </tr> |
---|
| 925 | <tr> |
---|
| 926 | <td colspan="4" style="text-align:center;"> |
---|
| 927 | <table width="1200" border="0" cellspacing="2" cellpadding="5" id="tablaImagen" align="center"> |
---|
| 928 | <tr> |
---|
| 929 | <td> |
---|
| 930 | <img src="img/pixelBlanco.jpg" width="0" height="0" style="border:0px solid #000000;" id="imagenPrevia"/> |
---|
| 931 | </td> |
---|
| 932 | </tr> |
---|
| 933 | </table> |
---|
| 934 | </td> |
---|
| 935 | </tr> |
---|
| 936 | |
---|
| 937 | <tr> |
---|
| 938 | <td colspan="4" style="text-align:center;"> |
---|
| 939 | |
---|
| 940 | </td> |
---|
| 941 | </tr> |
---|
| 942 | <tr> |
---|
| 943 | <td colspan="4" style="text-align:center;"> |
---|
| 944 | |
---|
| 945 | </td> |
---|
| 946 | </tr> |
---|
| 947 | <tr> |
---|
| 948 | <td colspan="4" style="text-align:center;"> |
---|
| 949 | VERIFICACIÓN DE FIRMAS |
---|
| 950 | </td> |
---|
| 951 | </tr> |
---|
| 952 | |
---|
| 953 | <tr> |
---|
| 954 | <td colspan="4" style="text-align:left;"><input id="archivoVerifica" name="archivoVerifica" type="file" data-min-file-count="1" name="min"></td> |
---|
| 955 | </tr> |
---|
| 956 | <tr> |
---|
| 957 | <td colspan="4" style="text-align:center;" id="progresoVerifica"> |
---|
| 958 | |
---|
| 959 | </td> |
---|
| 960 | </tr> |
---|
| 961 | <tr> |
---|
| 962 | <td colspan="4" style="text-align:center;" id="mensajeVerifica"> |
---|
| 963 | |
---|
| 964 | </td> |
---|
| 965 | </tr> |
---|
| 966 | <tr> |
---|
| 967 | <td colspan="4" style="text-align:center;"> |
---|
| 968 | <button type="button" class="button" name="botonSubeVerifica" id="botonSubeVerifica">Carga Archivo a Verificar</button> |
---|
| 969 | </td> |
---|
| 970 | </tr> |
---|
| 971 | |
---|
| 972 | <tr> |
---|
| 973 | <td colspan="4" style="text-align:center;"> |
---|
| 974 | <button type="button" class="button" name="botonEstadisticas" id="botonEstadisticas">Obtiene estadisticas</button> |
---|
| 975 | </td> |
---|
| 976 | </tr> |
---|
| 977 | |
---|
| 978 | </table> |
---|
| 979 | |
---|
| 980 | </body> |
---|
| 981 | </html> |
---|