<?php
	include("stilos/config.inc.php");
	include("../clases/BDConexion.php");
 
  include("../clases/clsPer.php");
  include("Funciones.php");
  session_start();
  $objPer=new clsPer;
  
  session_register("transper_d");
 
  if($borrar==1){
  $transper_d = array();  
  }
 
?>
<html>
<head>
<title><MMString:LoadString id="insertbar/formsHidden" /></title>
<link href="style.css" rel="stylesheet" type="text/css">
<link href="Estilos.css" rel="stylesheet" type="text/css">
<link href="stilos/Estilos.css" rel="stylesheet" type="text/css">
<SCRIPT language=JavaScript src="js/calendario.js"></SCRIPT>
<SCRIPT language=JavaScript src="js/ajax_dettp.js"></SCRIPT>
<SCRIPT language=JavaScript src="ajax_transper.js"></SCRIPT>
<? 
$envia="p_reg_trans.php?borrar=1";
$envia1="fondo.php";
?>
<script>
function volver(form)
{
location.reload('<? echo $envia ?>');
}
function salirse(form)
{
location.reload('<? echo $envia1 ?>');
}
</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>
</head>

<body bgcolor="<?=$c_fondo['fondo']?>" onfocus="foco()">
<table width="740" border="0" align="center" cellpadding="0" cellspacing="0" >
  <tr valign="top" >
    <td height="25" colspan="4">
    <div align="left" ></div></td>
  </tr>
  <tr class="lblCampo" >
    <td colspan="4"><div align="center">
        <form name="form1" method="post" action="procesos/p_reg_trans_g.php">
          <table width="730" border="0" cellspacing="0" cellpadding="0">
            <tr>
              <td width="25"><img src="../estilo_tabla/parte_sup_izq.gif" width="25" height="25"></td>
              <td width="680" background="../estilo_tabla/parte_sup_cen.gif" valign="bottom">
                <div align="left" class="lblTitulo" >Registro de Unidades de Transporte</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  background="../estilo_tabla/parte_med_izq.gif">&nbsp;</td>
              <td  height="86" background="../estilo_tabla/parte_med_cen.gif"><div align="center">
                  <table width="679" border="0" cellspacing="0" cellpadding="0">
                    <tr class="lblCampo">
                      <td colspan="6">&nbsp; </td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Empresa</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <select name="cod_emp" class="lblForm1" id="select3" onkeyup=fn(this.form,this)>
                          <option value="0">Seleccione</option>
                          <? 
							echo $objPer->getCboEmp1($cod_emp);
							?>
                        </select>
</div></td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td>Nave</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td width="120"><div align="left">Tipo de Unidad </div></td>
                      <td width="5"><div align="left">:</div></td>
                      <td width="193"><div align="left">
                        <select name="tipo_trans" id="select" onkeyup=fn(this.form,this)>
                          <option value="0" <? if($tipo_trans=="0"){?> selected <? }?>>Seleccionar Tipo</option>
                          <option value="AVIONETA" <? if($tipo_trans=="AVIONETA"){?> selected <? }?>>AVIONETA</option>
                          <option value="AVION">AVION</option>
                          <option value="RAPIDO">RAPIDO</option>
                          <option value="BARCAZA">BARCAZA</option>
                          <option value="HELICOPTERO">HELICOPTERO</option>
                          <option value="HIDROAVION">HIDROAVION</option>
                        </select>
                      </div></td>
                      <td width="128"><div align="left">Viaje que realiza </div></td>
                      <td width="5"><div align="left">:</div></td>
                      <td width="228">				      <div align="left">
                        <select name="via" id="via" onChange="enviar1(this.options[this.options.selectedIndex].value)">
                          <option value="0">Seleciona</option>
                          <option value="A">AEREO</option>
                          <option value="F">FLUVIAL</option>
                        </select>
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Matricula de Unidad </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="mat_trans" type="text" id="apellidos2" onKeyUp=fn(this.form,this) value="<? echo $mat_trans?>" size="20">
                      </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Modelo</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="model_trans" type="text" id="model_trans2" onKeyUp=fn(this.form,this) value="<? echo $model_trans?>" size="30">
                      </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Caracteristicas</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Asientos pax </div></td>
                      <td><div align="left">:</div></td>
                      <td>                        <div align="left">
                        <input name="cappass_trans" type="text" id="cappass_trans2" onKeyUp=fn(this.form,this) value="0" size="5">
</div></td>
                      <td>Asientos Tripulantes </td>
                      <td><div align="left">:</div></td>
                      <td><input name="tripnum_trans" type="text" id="tripnum_trans" onKeyUp=fn(this.form,this) value="0" size="5"></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Capacidad de Carga Int. </div></td>
                      <td><div align="left">:</div></td>
                      <td><div align="left">
                        <input name="capcarg_trans" type="text" id="capcarg_trans" onKeyUp=fn(this.form,this) value="0.00" size="8">
Kgs.
                        </div></td>
                      <td><div align="left">Max. Consumo Combustible </div></td>
                      <td><div align="left">:</div></td>
                      <td>                        <div align="left">
                        <input name="combus" type="text" id="combus" value="0.00" size="15">
                        <select name="tipomedida" id="tipomedida">
                          <option value="Gln/h">Gln/h</option>
                          <option value="Gln/v">Gln/v</option>
                        </select>
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Capacidad de Carga Ext. </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="capcarg_ext" type="text" id="capcarg_ext" onKeyUp=fn(this.form,this) value="0.00" size="8"> 
                        Kgs. 
                      </div></td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Tarifa</div></td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Fijo Mensual </div></td>
                      <td>&nbsp;</td>
                      <td><div align="left">
                        <input name="tarifam" type="text" id="tarifam" value="0.00" size="15">
                      </div></td>
                      <td><div align="left">Por hora </div></td>
                      <td>&nbsp;</td>
                      <td><div align="left">
                        <input name="tarifah" type="text" id="tarifah" value="0.00" size="15">
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Por Viaje</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="tarifav" type="text" id="tarifav" value="0.00" size="15">
                      </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Seguro</div></td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Inicio</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <table width="134" border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td width="67"><div align="left">
                                <input name="seguro_fi" type="text" id="seguro_fi" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<? echo $seguro_fi?>" size="12" maxlength="10">
                            </div></td>
                            <td width="10">&nbsp;</td>
                            <td width="109"><div align="left"> <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.seguro_fi');"> <img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"> </a> </div></td>
                          </tr>
                        </table>
                      </div></td>
                      <td><div align="left">Vencimiento</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <table width="134" border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td width="67"><div align="left">
                                <input name="seguro_ff" type="text" id="seguro_ff" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<? echo $seguro_ff?>" size="12" maxlength="10">
                            </div></td>
                            <td width="10">&nbsp;</td>
                            <td width="109"><div align="left"> <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.seguro_ff');"> <img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"> </a> </div></td>
                          </tr>
                        </table>
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Tipo de hora </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <select name="tipohora" id="tipohora">
                          <option value="V">Hora Volada</option>
                          <option value="T">Hora Tecnica</option>
                        </select>
                      </div></td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Operaciones</div></td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Fecha Inicio Op. </div></td>
                      <td>&nbsp;</td>
                      <td><div align="left">
                        <table width="134" border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td width="67"><div align="left">
                                <input name="fecha_iniop" type="text" id="fecha_iniop" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<? echo $fecha_iniop?>" size="12" maxlength="10">
                            </div></td>
                            <td width="10">&nbsp;</td>
                            <td width="109"><div align="left"> <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.fecha_iniop');"> <img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"> </a> </div></td>
                          </tr>
                        </table>
                      </div></td>
                      <td><div align="left">Fecha Termino Op.</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <table width="134" border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td width="67"><div align="left">
                                <input name="fecha_finop" type="text" id="fecha_finop" title="FORMATO dd/mm/AA" onKeyUp=fn(this.form,this) value="<? echo $fecha_finop?>" size="12" maxlength="10">
                            </div></td>
                            <td width="10">&nbsp;</td>
                            <td width="109"><div align="left"> <a onMouseOver="window.status='Calendario';return true;" onMouseOut="window.status='';return true;"  href="javascript:show_calendar('form1.fecha_finop');"> <img src="../imagenes/calendar.jpg" alt="Calendario" width="16" height="15" border="0"> </a> </div></td>
                          </tr>
                        </table>
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">N&ordm; Contrato Ord. Servicio </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="numcontrato" type="text" id="numcontrato" size="20">
                      </div></td>
                      <td><div align="left">Dias de Indisponiblidad Otor. </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="dias_indotor" type="text" id="dias_indotor" value="0" size="5">
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Hora Max. x Dia </div></td>
                      <td>&nbsp;</td>
                      <td><div align="left">
                        <input name="horamaxtra" type="text" id="horamaxtra" value="0" size="5">
                      </div></td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Costo Movilizacion </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="costo_mov" type="text" id="costo_mov" value="0.00" size="15">
                      </div></td>
                      <td><div align="left">Costo Desmovilizacion </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <input name="costo_desmov" type="text" id="costo_desmov" value="0.00" size="15">
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td><div align="left">Comentario</div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left">
                        <textarea name="comentario" cols="30" id="comentario"></textarea>
                      </div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                      <td><div align="left"></div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td colspan="6"><div align="left">Personal Adicional </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td colspan="6"><div align="left" id="cuerpo_tp">
                      </div></td>
                    </tr>
                    <tr class="lblCampo">
                      <td colspan="6"><div align="left" id="mensaje1"></div></td>
                    </tr>
                    <tr class="normal">
                      <td colspan="6">
                        <hr align="left" size="1" color="#000000">
                      </td>
                    </tr>
                    <tr class="normal">
                      <td colspan="6">
					    <div align="center">
					      <table width="660" border="0" cellpadding="0" cellspacing="0">
                            <tr>
                              <td width="250"><div align="right">
                                <input name="boton_grabar" type="button" class="botira" id="boton_grabar" style="<?=$stylo['st2']?>" onClick="enviarDatosGrabarReg()" value=".:        Grabar       :.">
                              </div></td>
                              <td width="160"><div align="center">
                                <input name="boton_nuevo" type="button" class="botira" id="boton_nuevo" style="<?=$stylo['st2']?>" onClick="volver(this.form);"  value=".::        Nuevo        ::.">
                              </div></td>
                              <td width="250"><div align="left">
                                <input name="boton_salir" type="button" class="botira" id="boton_salir" style="<?=$stylo['st2']?>" onClick="salirse(this.form);" value=".:          Salir         :.">
                              </div></td>
                            </tr>
                          </table>
			          </div></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="rect" coords="3,4,23,21" href="fondo.php">
</map>
</body>
</html>

