<%@ page language="java"%> 

<%@ page import="java.util.*,javax.sql.*,java.sql.*,javax.naming.*,java.text.*,m05bClasses.m05bConstantesPaginas,,m05bClasses.m05bComun" %>
<%
	// _______________________________XLNETs______________________________________
	// Evaluar variable de session que indica si esta conectado a XLNets
	if ((session.getAttribute("objetoSeguridad")) == null)  { 
		// Verificar que no ha transcurrido el tiempo de sesion (web.xml) %>
			<%@ include file="/m05bControlAcceso.inc"%> <%
	} 
%>	
<%@ include file="/m05bIdioma.inc"%>
<HTML>
<HEAD>
    <link rel="stylesheet" href="<%=m05bConstantesPaginas.PATH_ESTILOS%>/m05bestilos.css" type="text/css">
	<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
</HEAD>	

<%	m05bComun miComun = new m05bComun();
	String tarjDup = miComun.leerPropiedad("PDF.TarjDuplicado"); 
%>

<BODY style="cursor: wait" onload="document.body.style.cursor='default';document.all['general'].style.visibility='visible';document.all['general'].style.cursor='default';" onunload="document.body.style.cursor='wait';document.all['general'].style.cursor='wait';">
<div  id="general" style="POSITION: absolute;visibility:hidden;cursor: wait">	
<form NAME="formPDFTarjDupli" METHOD="POST">
<%
	String matricula = request.getParameter("Matricula");
    String sIncidencia=request.getParameter("IncidenciaHid");
    String sPlastico=request.getParameter("Plastic");
    String sNcta=request.getParameter("NCtaT");
    String sLimite=request.getParameter("Limite");
    String sTarjeta=request.getParameter("Codigo");
    String sHisTarjeta=request.getParameter("CodInterno");
    String sCentro=request.getParameter("CentroT");
    String sTipo=request.getParameter("Tipo");
    String sTipoT=request.getParameter("TipoT");
    
	String srcPDF = tarjDup + "?Matricula="+matricula;
	srcPDF = srcPDF + "&Incidencia=" + sIncidencia;
	srcPDF = srcPDF + "&Plastic=" + sPlastico;
	srcPDF = srcPDF + "&NCta=" + sNcta;
	srcPDF = srcPDF + "&Limite=" + sLimite;
	srcPDF = srcPDF + "&Codigo=" + sTarjeta;	
	srcPDF = srcPDF + "&CodInterno=" + sHisTarjeta;	
	srcPDF = srcPDF + "&CentroT=" + sCentro;
	srcPDF = srcPDF + "&Tipo=" + sTipo;
	srcPDF = srcPDF + "&TipoT=" + sTipoT;
%>
	
<TABLE class="general">
  <tr>
    <!--td width="90%" align="right"><INPUT TYPE="IMAGE" style="cursor:hand" VALUE="Retornar" ONCLICK="JavaScript:fncRetornar('<%=matricula%>','<%=sHisTarjeta%>');" onMouseOver="top.status='Retornar'; return true" onMouseOut="top.status=''; return true" src="<%=m05bConstantesPaginas.PATH_IMAGENES%>/retornar.gif"></td-->
    <td width="90%" align="right"><input type="button" class="boton" name="<%= res.getString("etBOT_RETORNAR")%>" value="<%= res.getString("etBOT_RETORNAR")%>" ONCLICK="JavaScript:fncRetornar('<%=matricula%>','<%=sHisTarjeta%>');" onMouseOver="top.status='<%= res.getString("etBOT_STATUSRETORNAR")%>'; return false" onMouseOut="top.status=''; return false" /></td>				      					      
  </tr>
  <tr>
    <td colspan="2">
		<embed name='pdfTarjDupli' src='<%=srcPDF%>' type="application/pdf" width='736' height='500'></embed>
  	</td>
  </tr>
</TABLE>
</form>
<script type="text/javascript" src="<%=m05bConstantesPaginas.PATH_SCRIPTS%>/m05bMsControl.js"></script>
 
</div>	  
</body>
<SCRIPT language=JavaScript>
	function fncRetornar(matricula,histarjeta) {
		var docu = document.formPDFTarjDupli;
		docu.action="/m05bParqueMovilWar/m05bGenerarHisTarjetasServlet?Matricula="+ matricula +"&CodInterno=" + histarjeta;
		docu.submit();
	}
</SCRIPT>
</html>