<?php

//ini_set('display_errors',1);

session_start();
require_once ("../../config/Cado.php");
require_once ("cCaja.php");
$oCaja = new cCaja();

if($_POST['vista']=="venta"){
	
}else{
?>
	<option value="">---Seleccionar---</option>
<?php
}

	if($_POST['tip'] == 4){
		$like = "BND";
	}else if($_POST['tip']==3){
		$like = "RTC";
	}
 
		//echo $_POST['tip'].'-'.$_POST['mon_id'].'-'.$_POST['emp_id'].'-'.$like;

	$dts1=$oCaja->filtrar2($_POST['tip'],$_POST['mon_id'],$_POST['punven_id'],$like);
	while($dt1 = mysqli_fetch_array($dts1))
	{		
	?>
	<option value="<?php echo $dt1['tb_caja_id']?>" <?php if($dt1['tb_caja_id']==$_POST['caj_id']) echo 'selected'?>>
	<?php echo $dt1['tb_banco_nom'].' - '.$dt1['tb_moneda_sim'].' | '.$dt1['tb_puntoventa_nom'].' '.$dt1['tb_empresa_nomcom']; ?></option>
	<?php
	}
	mysqli_free_result($dts1);
?>