<?php
  include("../stilos/config.inc.php");
  include("../clases/BDConexion.php");
  include("stilos/config.inc.php");
  include("../clases/clsReq.php");
  include("Funciones.php");
  include("funcion/funciones.php");
  $objPer=new clsReq;
  session_start();
  session_register("conceptosAuto");
  if ($borrar == 1){
     $conceptosAuto = array();
      }
  
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Registro de Examenes Clinicos - BARRET RESOURCES(PERU) LLC</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="stilos/Estilos.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.Estilo2 {color: #000000}
.Estilo3 {color: #000000; font-size: 10px; }
.Estilo4 {color: #FFFFFF}
-->
</style>
<SCRIPT language=JavaScript src="js/calendario.js"></SCRIPT>
<script>
function enviar_url(form,url){
		if(form1.grabar.value)
		{
			form1.submit();
		}
	}
</script>
<SCRIPT LANGUAGE=javascript>
function fn(form,field)
	{
	var next=0, found=false
	var f=form
	if(event.keyCode!=13) return;
	for(var i=0;i<f.length;i++) {
	if(field.name==f.item(i).name){
	next=i+1;
	found=true
	break;
	}
	}
while(found){
	if( f.item(next).disabled==false && f.item(next).type!='hidden'){
	f.item(next).focus();
	break;
	}
	else{
	if(next<f.length-1)
	next=next+1;
	else
	break;
	}
		}
}
</SCRIPT>
<script language="JavaScript"> 
<!--
//sURL,x,y
function Abrir_Ventanapopup1(sURL,x,y) { 
/*var especificaciones="top=0, left=0, toolbar=no,location=no, status=yes,menubar=no,scrollbars=no, resizable=no, width=1,height=1" 
var titulo="Titulo"
window.open(el_url,titulo,especificaciones);*/ 

if (!window.focus) return;
			var par;
			par = "width=" +x + ",height="+y+","
			par = par + "dependent=no,scrollbars=yes,resizable=no"
			par = par + "menubar=no,toolbar=no,status=yes"
			var ventana = window.open(sURL,"Ver",par)
			ventana.focus();
}
//--> 
</script>

<script language="JavaScript" type="text/JavaScript">
function MensajeEditar(m){
if (m==1){window.alert("Se Guardo el Examen satisfactoriamente")}
}
</script>
<script>
var vent = null;
function foco() {
   if (vent != null)
       vent.focus();
}


function cerrar() {
   vent = null;
}
function volver(form){
  location.reload('cvp_evalua_coti.php');
  }
</script>
<script language="javascript" type="text/javascript">
	function Enviarse(){
			 if (document.form1.concepto.value==""){alert ("No Escribio la Descripcion del Documento"); document.form1.concepto.focus();return;}
			 if(isNaN(form1.cantidad.value) || form1.cantidad.value=="" ){ alert("Debe Ingresar la Cantidad en Valor Numerico y es Obligatorio!!");	form1.cantidad.focus(); return;}
			 if(isNaN(form1.precio.value) || form1.precio.value=="" ){alert("Debe Ingresar el precio en Valor Numerico y Es Obligatorio!!");form1.precio.focus();return;}
			 var concepto = document.form1.concepto.value;
			 var unidad = document.form1.unidad.value;
			 var cantidad = document.form1.cantidad.value;
			 var precio = document.form1.precio.value;
			 var dolar = document.form1.dolar.value;
			 var proveedor = document.form1.proveedor.value;
			 var ruc = document.form1.ruc.value;
			 var codigoEmp = document.form1.codigoEmp.value;
			 var CondicionPago = document.form1.CondicionPago.value;
			 var tipodoc = document.form1.tipodoc.value;
			 var ndoc = document.form1.ndoc.value;
			 var fecha_req2 = document.form1.fecha_req2.value;
			 var id_auto = document.form1.id_auto.value;
			 cantidad = parseFloat(cantidad);
			 precio = parseFloat(precio);
			 precio = precio.toFixed(2); 
			 var total = precio * cantidad;
			 total = total.toFixed(2);
			 var simbolom;
			 if (dolar!=""){simbolom = '$/.';} else {simbolom = 'S/.';}
			 window.location="procesos/cvp_autorizacionesdecosto_agregarItem.php?concepto="+concepto+"&unidad="+unidad+"&cantidad="+cantidad+"&precio="+simbolom + " "+precio+"&dolar="+dolar+"&total="+simbolom + " "+total+"&proveedor="+proveedor+"&ruc="+ruc+"&codigoEmp="+codigoEmp+"&totales="+total+"&simbolom="+simbolom+"&CondicionPago="+CondicionPago+"&tipodoc="+tipodoc+"&ndoc="+ndoc+"&fecha_req2="+fecha_req2+"&id_auto="+id_auto;
			  }
			  
function ClickLista(){
            var codigoEm = document.form1.tipo_empProv.value;
			var id_auto = document.form1.id_auto.value;
			var fecha_req2 = document.form1.fecha_req2.value;
			var CondicionPago = document.form1.CondicionPago.value;
			window.location = "procesos/cvp_buscarEmpresaproveedora.php?codigoEm="+codigoEm+"&id_auto="+id_auto+"&fecha_req2="+fecha_req2+"&CondicionPago="+CondicionPago;   

                  }
</script>
<script language="javascript" type="text/javascript">
  function Dato(){
             document.form1.dolar.value=1;
			 document.form1.soles.value="";
			 }
  function Dato1(){
             document.form1.dolar.value="";
			 document.form1.soles.value=1;
			 }
  function NuevoProvvedor(){
  
     window.location = "cvp_nueva_empresa_proveedor.php";
                }

   function GrabarAutorizacionGasto(){
   	   var contArray = document.form1.contArray.value;
       if (document.form1.proveedor.value==""){alert ("No ha Elegido al Proveedor del Documento"); document.form1.tipo_empProv.focus();return;}
       contArray = parseInt(contArray);
	   if (contArray==0){alert ("No ha Agregado Un Concepto de Gasto a la Lista"); document.form1.concepto.focus();return;}
	   form1.submit();
	   
  }
  
  function RegresaAtras(){  window.location='fondo.php';  }
 
</script>
<link href="../stilos/Estilos.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
.Estilo5 {color: #FFFFFF; font-size: 10px; }
.Estilo6 {font-weight: bold}
.Estilo7 {text-align : justify; color : White; font-size : 9px; margin-right:5px; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;}
.Estilo8 {text-align : justify; color : Black; font-size : 9px; margin-right:5; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;}
-->
</style>
</head>
<body  background="../imagenes/fondo.jpg" onLoad="">
<table width="700" border="0" align="center" cellpadding="0" cellspacing="0" >
  <tr class="lblCampo" >
    <td colspan="4"><div align="center">
	<form action="procesos/cvp_grabarautorizaciones.php" method="post" name="form1" class="Estilo6">	
        <table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
            <td>&nbsp;</td>
            <td valign="bottom">&nbsp;</td>
            <td>&nbsp;</td>
          </tr>
          <tr>
            <td width="27"><img src="../estilo_tabla/parte_sup_izq.gif" width="25" height="25"></td>
            <td width="808" background="../estilo_tabla/parte_sup_cen.gif" valign="bottom">
              <div align="left" class="lblTitulo Estilo4" >Autorizaci&oacute;n Para Gastos </div></td>
            <td width="25"><img src="../estilo_tabla/parte_sup_der.gif" width="25" height="25" border="0" usemap="#Map"></td>
          </tr>
          <tr>
            <td width="27" background="../estilo_tabla/parte_med_izq.gif">&nbsp;</td>
            <td width="808" height="86" background="../estilo_tabla/parte_med_cen.gif"><div align="center">
              <table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
                <tr>
                  <td width="3" >&nbsp;</td>
                  <td width="3" height="19">&nbsp; </td>
                  <td width="684">&nbsp;</td>
                  <td width="163">&nbsp;</td>
                  <td width="3">&nbsp;</td>
                </tr>
                <tr>
                  <td>&nbsp;</td>
                  <td colspan="3" valign="top"><table width="700" border="0" align="center" cellpadding="0" cellspacing="0" >
                      <tr>
                        <td colspan="3" valign="top" class="Estilo4">
                            <div align="center">
                              <table width="700" border="0" align="center" cellpadding="0" cellspacing="0" id="apell_nom">
                                  <tr bgcolor="#0000cc">
                                    <td align="center" >                                  
                                    <div align="center">                                  </div></td>
                                    <td width="68" ><div align="left" class="Estilo4">
                                      <div align="left">Direcc&oacute;n</div>
                                    </div></td>
                                    <td width="8"  class="Estilo4">:</td>
                                    <td align="left" class="Estilo7">Canaval y Moreyra # 380, Of. 1002 </td>
                                    <td align="left" class="Estilo7">&nbsp;</td>
                                    <td colspan="2" align="left" class="Estilo7"><div align="right">N&ordm; de Autorizaci&oacute;n</div></td>
                                    <td align="left" class="Estilo7">:</td>
                                    <td colspan="2" ><div align="left" class="Estilo4">
                                      <div align="left">&nbsp;&nbsp;001-0
                                        <input name="id_auto" type="text" class="Estilo8" id="id_auto" value="<?php if($id_auto==""){echo $objPer->DevolverNumeAutoriza();}else{ echo $id_auto;}?>" size="4">
                                      </div>
                                    </div></td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td align="center">&nbsp;</td>
                                    <td class="Estilo4" ><div align="left">Ruc</div></td>
                                    <td class="Estilo4">:</td>
                                    <td width="257" align="left" class="Estilo7">20332473388</td>
                                    <td width="81" align="left" class="Estilo7">&nbsp;</td>
                                    <td colspan="2" class="Estilo7"><div align="right">Fecha</div></td>
                                    <td width="4" class="Estilo7">:</td>
                                    <td colspan="2"><div align="left"><span class="Estilo4">
                                        <input name="fecha_req2" type="text" class="Estilo8" id="fecha_req2" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<? if(!isset($fecha_req2)){echo date("d/m/Y");} else {echo $fecha_req2;} ?>" size="12" maxlength="10">
                                    <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.fecha_req2');"><img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"></a> </span></div></td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td align="center">&nbsp;</td>
                                    <td class="Estilo4" ><div align="left">Tel&eacute;fono</div></td>
                                    <td>:</td>
                                    <td align="left" class="Estilo7">01-6151600</td>
                                    <td align="left" class="Estilo7">&nbsp;</td>
                                    <td colspan="2" class="Estilo7"><div align="right">Condici&oacute;n de Pago </div></td>
                                    <td class="Estilo7">:</td>
                                    <td colspan="2"><div align="left">
                                      <select name="CondicionPago" class="Estilo8">
                                          <option value="Contado"<?php if ($CondicionPago=='Contado'){echo 'selected';}elseif(!isset($CondicionPago)){echo 'selected';}?>>Contado</option>
                                          <option value="7 dias" <?php if ($CondicionPago=='7 dias'){echo 'selected';}?>>7 d&iacute;as</option>
                                          <option value="15 dias" <?php if ($CondicionPago=='15 dias'){echo 'selected';}?>>15 d&iacute;as</option>
                                          <option value="30 dias" <?php if ($CondicionPago=='30 dias'){echo 'selected';}?>>30 d&iacute;as</option>
                                      </select>
                                    </div></td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td align="center">&nbsp;</td>
                                    <td class="Estilo4" >&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td align="left" class="Estilo7">&nbsp;</td>
                                    <td align="left" class="Estilo7">&nbsp;</td>
                                    <td colspan="2" class="Estilo7">&nbsp;</td>
                                    <td class="Estilo7">&nbsp;</td>
                                    <td colspan="2">&nbsp;</td>
                                  </tr>
                                  <tr bgcolor="#ffffff">
                                    <td align="center">&nbsp;</td>
                                    <td class="Estilo4" >&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td align="left" class="Estilo7">&nbsp;</td>
                                    <td align="left" class="Estilo7">&nbsp;</td>
                                    <td colspan="3" class="Estilo7"><div align="right"></div></td>
                                    <td colspan="2">&nbsp;</td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td width="15"><div align="right" class="Estilo2">
                                        <div align="center">                                    </div>
                                    </div></td>
                                    <td colspan="6" ><div align="left" class="Estilo4">Buscar Proveedor
                                      <?=$objPer->TiposEmpresaProveedora("tipo_empProv",$valor)?> 
                                      <span class="Estilo8">
                                      <input type="button" name="Submit" value="Nuevo" style="<?=$stylo['st2']?>" class="botira" onClick="NuevoProvvedor();">
</span><span class="Estilo8"><input name="codigoEmp" type="hidden" id="fechaCoti2" value="<?= $codigoEmp?>">
                                    </span></div>                                    </td>
                                    <td>&nbsp;</td>
                                    <td colspan="2">&nbsp;</td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td>&nbsp;</td>
                                    <td class="Estilo7" >Proveedor </td>
                                    <td><span class="Estilo4">:</span></td>
                                    <td><div align="left"><span class="Estilo4">
                                        <input name="proveedor" type="text" class="Estilo8" id="proveedor" value="<?=$proveedor?>" size="50">
                                    </span></div></td>
                                    <td>&nbsp;</td>
                                    <td width="94"><div align="right" class="Estilo4">Moneda</div></td>
                                    <td width="20"><div align="right">
                                      <input name="moneda" type="radio" value="1" <?php if ($dolar==1){echo "checked";}?> onClick="Dato();">
                                    </div></td>
                                    <td>&nbsp;</td>
                                    <td colspan="2" class="Estilo4"><div align="left"> Dolares ($/.)
                                      <input type="hidden" name="dolar">
                                    </div></td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td>&nbsp;</td>
                                    <td class="Estilo7" >RUC</td>
                                    <td class="Estilo4"><div align="center"> : </div></td>
                                    <td><div align="left"><span class="Estilo4">
                                        <input name="ruc" type="text" class="Estilo8" id="ruc" value="<?=$ruc?>" size="50">
                                    </span></div></td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td><div align="right">
                                      <input name="moneda" type="radio" value="2" <?php if ($dolar==""){echo "checked";} else{if ($borrar==1){echo "checked";}}?> onClick="Dato1();">
                                    </div></td>
                                    <td>&nbsp;</td>
                                    <td colspan="2" class="Estilo4"><div align="left">Soles (S/.) 
                                      <input type="hidden" name="soles" value="1">
                                    </div></td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td > <div align="right">
                                    </div></td>
                                    <td ><div align="left"></div></td>
                                    <td>&nbsp;</td>
                                    <td colspan="7"><div align="left">
                                    </div></td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td >&nbsp;</td>
                                    <td colspan="3" >&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                  </tr>
                                  <tr bgcolor="#ffffff">
                                    <td >&nbsp;</td>
                                    <td colspan="9" ><div align="left"><span class="Estilo2">Agregar Concepto </span></div></td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td rowspan="2" >&nbsp;</td>
                                    <td colspan="3" rowspan="2" ><div align="left">
                                      <textarea name="concepto" cols="60" rows="2" class="Estilo8" id="concepto"></textarea>
                                    </div></td>
                                    <td><div align="center">UM</div></td>
                                    <td><div align="center">Cantidad</div></td>
                                    <td rowspan="2">&nbsp;</td>
                                    <td rowspan="2">&nbsp;</td>
                                    <td>Precio</td>
                                    <td width="80">&nbsp;</td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td><select name="unidad" class="lblForm" id="unidad">
                                      <option value="Unidad">Unidad</option>
                                      <option value="Paquete">Paquete</option>
                                      <option value="KG">KG</option>
                                      <option value="Litro">Litro</option>
                                      <option value="Galon">Gal&oacute;n</option>
									  <option value="Millar">Millar</option>
									  <option value="xHora">xHora</option>
                                    </select></td>
                                    <td><div align="center">
                                      <input name="cantidad" type="text" class="lblForm" id="cantidad" size="10">
                                    </div></td>
                                    <td width="73"><input name="precio" type="text" class="lblForm" id="precio" size="10"></td>
                                    <td width="80">&nbsp;</td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td >&nbsp;</td>
                                    <td colspan="3" ><div align="left">Referencia</div></td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                  </tr>
                                  <tr bgcolor="#0000cc">
                                    <td >&nbsp;</td>
                                    <td colspan="3" ><select name="tipodoc" class="lblForm">
                                      <option value="Factura" <?php if ($tipodoc=='Factura'){echo 'selected';}elseif(!isset($tipodoc)){echo 'selected';}?>>Factura</option>
                                      <option value="Boleta"<?php if ($tipodoc=='Boleta'){echo 'selected';}?>>Boleta</option>
                                      <option value="Guia Remision">Gui de Remisi&oacute;n</option>
                                      <option value="Ticke" <?php if ($tipodoc=='Ticke'){echo 'selected';}?>>Ticke</option>
                                      <option value="Nota de Credito" <?php if ($tipodoc=='Nota de Credito'){echo 'selected';}?>>Nota de Credito</option>
                                      <option value="Recibo" <?php if ($tipodoc=='Recibo'){echo 'selected';}?>>Recibo</option>
                                      <option value="Recibo por Honorario" <?php if ($tipodoc=='Recibo por Honorario'){echo 'selected';}?>>Recibo por Honorario</option>
                                    </select>
                                      N&ordm;
                                    <input name="ndoc" type="text" class="lblForm" id="ndoc2" value="<?=$ndoc?>" size="25"></td>
                                    <td><input name="Submit2" type="button" class="lblForm" value="Agregar&gt;&gt;" onClick="Enviarse();"></td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                    <td>&nbsp;</td>
                                  </tr>
                              </table>
                            </div>
                        </td>
                      </tr>
                      <tr>
                        <td colspan="3"><div align="center">
                            <table width="700" border="0" align="center" cellpadding="0" cellspacing="0">
                              <tr>
                                <td colspan="3"><div align="center">
                                    <table width="700" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="<?=$bordetabla?>" bgcolor="<?=$c_fondo['fondo tabla']?>" style="<?=$stylo['tabla']?>">
                                      <tr valign="top" class="lblCampoBlanco" bgcolor="<?=$c_fondo_tr["fondo tr"]?>">
                                        <td width="45"> <div align="center">ITEM</div></td>
                                        <td width="229" > 
                                          <div align="center">Descripcion</div>
                                       </td>
                                        <td width="77" ><div align="left">Tipo Doc. </div></td>
                                        <td width="74" ><div align="left">N&ordm; Doc. </div></td>
                                        <td width="43" >
                                          <div align="center">UM</div>
                                        </td>
                                        <td width="61" ><div align="center">CANTIDAD</div></td>
                                        <td width="50" >PRECIO</td>
                                        <td width="59" >
                                          TOTAL</td>
                                        <td width="42" ><div align="center">QUITAR</div></td>
                                      </tr>
									<?php //echo !isset($des);
									   	$suma = 0;
										$totalElem = 0;
										if(isset($conceptosAuto)){
						                while(list($clave,$valor)=each($conceptosAuto)){
									?>
                                      <tr valign="top" class="lblForm">
                                        <td><div align="center"><? echo $clave + 1; ?></div></td>
                                        <td><div align="left"><? echo $valor[0]; ?></div></td>
                                        <td><div align="center"><? echo $valor[6]; ?></div></td>
                                        <td><div align="center"><? echo $valor[7]; ?></div></td>
                                        <td><div align="center"><? echo $valor[1]; ?> </div></td>
                                        <td align="center"><? echo $valor[2];  ?></td>
                                        <td align="right"><? echo $valor[3]; ?></td>
                                        <td>
                                          <div align="right"><? echo $valor[4]; ?> </div></td>
                                        <td><div align="center"><a href="procesos/cvp_borrarItem_autorizaciondepago.php?clave=<?=$clave?>&fecha_req2=<?=$fecha_req2?>&CondicionPago=<?=$CondicionPago?>&proveedor=<?=$proveedor?>&ruc=<?=$ruc?>&tipodoc=<?=$tipodoc?>&ndoc=<?=$ndoc?>&dolar=<?=$dolar?>&codigoEmp=<?=$codigoEmp?>&simbolom=<?=$simbolom?>&id_auto=<?=$id_auto?>"><img src="../imagenes/btn_eliminar.gif" width="20" height="20" border="0"></a>
</div></td>
                                      </tr>
									  <?php 
									  	 $suma = $suma + $valor[5]; 
										 $totalElem = count($conceptosAuto);
										}
									  }
									  ?>
                                     </table>
                                </div></td>
                              </tr>
                              <tr>
                                <td width="356" rowspan="3"><div align="left"><span class="Estilo6">Observaciones</span>                                      <textarea name="observacion" cols="50" rows="2" class="Estilo8" id="observacion"></textarea>
                                </div></td>
                                <td width="196"><div align="right"><strong>
                                  <input type="hidden" name="contArray" value="<?=$totalElem?>">
                                  Sin IGV </strong></div></td>
                                <td width="148" bordercolor="#000000"><?=$simbolom." ".number_format($suma,2,'.','')?>	</td>
                              </tr>
                              <tr>
                                <td width="196"><div align="right"><strong>IGV</strong></div></td>
                                <td bordercolor="#000000"><?=" ---- "?>
                                  <input type="hidden" size="6" name="totales" value="<?=$simbolom." ".number_format($suma,2,'.','')?>"></td>
                              </tr>
                              <tr>
                                <td width="196"><div align="right"><strong>Total</strong></div></td>
                                <td bordercolor="#000000"><?=$simbolom." ".number_format($suma,2,'.','')?></td>
                              </tr>
                            </table>
                        </div></td>
                      </tr>
                      <tr>
                        <td colspan="3">&nbsp;</td>
                      </tr>
                      <tr>
                        <td colspan="3">
						<table width="700" border="1" cellspacing="0" cellpadding="0" style="<?=$stylo['tabla']?>" bgcolor="<?=$c_fondo['fondo tabla']?>" bordercolor="<?=$bordetabla?>">
                          <tr bgcolor="<?=$c_fondo_tr["fondo tr"]?>" class="lblCampoBlanco">
                            <td width="224">Solicitado Por</td>
                            <td width="253">Aprobado por </td>
                            <td width="215">Representado Por</td>
                          </tr>
                          <tr>
                            <td><div align="left">Nombre:
                              <input name="solinombre" type="text" class="lblForm" id="solinombre" size="30">
                            </div></td>
                            <td><div align="left">Nombre:
                              <input name="aprobnombre" type="text" class="lblForm" id="aprobnombre" size="30">
                            </div></td>
                            <td><div align="left">Nombre:
                              <input name="reperesnombre" type="text" class="lblForm" id="reperesnombre" size="30">
                            </div></td>
                          </tr>
                          <tr>
                            <td><div align="left">Fecha:&nbsp;&nbsp;&nbsp;
                                <span class="Estilo4">
                                <input name="fecha1" type="text" class="Estilo8" id="fecha1" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<? echo $fecha1; ?>" size="12" maxlength="10">
                                <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.fecha1');"><img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"></a> </span> </div></td>
                            <td><div align="left">Fecha:&nbsp;&nbsp;&nbsp;
                                <span class="Estilo4">
                                <input name="fecha2" type="text" class="Estilo8" id="fecha2" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<?echo $fecha2;?>" size="12" maxlength="10">
                                <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.fecha2');"><img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"></a> </span> </div></td>
                            <td><div align="left">Fecha:&nbsp;&nbsp;&nbsp;                                <span class="Estilo4">
                                <input name="fecha3" type="text" class="Estilo8" id="fecha3" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<?echo $fecha3;?>" size="12" maxlength="10">
                                <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.fecha3');"><img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"></a> </span> </div></td>
                          </tr>
                          <tr>
                            <td><div align="left">Firma:&nbsp;&nbsp;&nbsp;&nbsp;
                            </div></td>
                            <td><div align="left">Firma:&nbsp;&nbsp;&nbsp;&nbsp;
                            </div></td>
                            <td><div align="left">Firma:&nbsp;&nbsp;&nbsp;&nbsp;
                            </div></td>
                          </tr>
                        </table></td>
                      </tr>
                      <tr>
                        <td width="354"><div align="right">
                          <input name="Submit3" type="button" value="Grabar Autorizaci&oacute;n" onClick="GrabarAutorizacionGasto();">
                        </div></td>
                        <td width="173">&nbsp;</td>
                        <td width="173"><input name="Submit32" type="button" value="Cancelar" onClick="RegresaAtras()">
                        </td>
                      </tr>
                  </table></td>
                  <td>&nbsp;</td>
                </tr>
              </table>
                </div></td>
            <td background="../estilo_tabla/parte_med_der.gif">&nbsp;</td>
          </tr>
          <tr>
            <td><img src="../estilo_tabla/parte_inf_izq.gif" width="25" height="25"></td>
            <td background="../estilo_tabla/parte_inf_cen.gif">&nbsp;</td>
            <td><img src="../estilo_tabla/parte_inf_der.gif" width="25" height="25"></td>
          </tr>
        </table>
		</form>
		
		
		
    </div></td>
  </tr>
  <tr valign="top" class="lblCampo" >
    <td colspan="4">
      <div align="center"> </div></td>
  </tr>
</table>
<map name="Map">
  <area shape="circle" coords="12,11,9" href="fondo.php">
</map>
</body>
</html>
