<?php
/* @var $this UtilidadController */
/* @var $model Utilidad */

  $ganancia=$ingreso-$egreso;

?>

   
  
<div class="row justify-content-center mt-3 p-3">
  <fieldset class="col-12 col-sm-12 col-md-12 ">
    <legend> DATOS A CONSULTAR</legend>

     <?php $this->renderPartial('_search',array(
         'consultar'=>$consular,
 )); ?>
    
  </fieldset>
     </div>       
        
 
  


    <div class="row justify-content-center">
        <div class="col-12 col-sm-12 col-md-3 col-lg-3 col-xl-3 " style="color:#000; font-weight:bold; font-size:18px;">
            INGRESOS: <?php echo $ingreso ?>
        </div>
        <div class="col-12 col-sm-12 col-md-3 col-lg-3 col-xl-3" style="color:#000; font-weight:bold; font-size:18px;">
            EGRESOS:  <?php echo $egreso ?> 
        </div>
        <div class="col-12 col-sm-12 col-md-3 col-lg-3 col-xl-3" style="color:#000; font-weight:bold; font-size:18px;" >
            GANANCIAS: <?php echo $ganancia ?> 
        </div>

    </div>


            
            
            <br>
            <div class="row mt-5">
                <div class="col-12 text-center" style="color:#000; font-weight:bold; font-size:18px;" >

<?php 
        $this->widget(
            'chartjs.widgets.ChBars', 
            array(
                'width' => 600,
                'height' => 300,
                'htmlOptions' => array(),
                'labels' => array("INGRESOS","EGRESOS","GANANCIAS"),
                'datasets' => array(
                    array(
                        "fillColor" =>array( "rgb(255,124,51)"),
                        "strokeColor" => "rgb(255,124,51)",
                        "pointColor" => "rgb(255,124,51)",
                        "pointStrokeColor" => "rgb(255,124,51)",

                        "data" => array($ingreso, $egreso, $ganancia)
                    ),
                    
                ),
                'options' => array()
            )
        ); 
    ?>

                </div>
            </div>      
            
            
            
            
            
            
    </div>
 </div> 
       
       
      
       
       
       
       
</div>
