include_once "../controller/cUtilerias.php";
include_once "../helper/crearTablaAmortizacion.php";
include_once "../helper/imprimeTablaAmort2.php";
if ($_POST) {
    if ($_POST['operacion'] == 'mostrar') {
        $tabla = new Tabla();
        // print_r($_POST);
        $total = $_POST['total'];
        $tasa = $_POST['tasa'];
        $tipopago = $_POST['tipop'];
        $nabon = $_POST['nabon'];
        $abono = $_POST['abono'];
        $fecha = $_POST['fecha'];
        $datos = $tabla->getTis($tipopago, $tasa);
        $tabla->getHeader($total, $datos, $nabon, $tasa, $abono);
        $table = $tabla->getTablaAmortizacion($total, $tasa, $tipopago, $nabon, $abono, $fecha);
        $cantidad = sizeof($table);
        ?>
			<div style="background-color: white">
				<table class="table table-striped" id="tblAmortz">
					<thead>
						<th>#</th>
						<th>SALDO INSOLUTO</th>
						<th>CAPITAL PAGADO</th>
						<th style="text-transform: uppercase">% INTER&Eacute;S <?php 
        echo $datos['tipopago'];
        ?>
</th>
						<th>INTER&Eacute;S</th>
						<th>PAGO</th>