Example #1
0
 static function obtenerHastaLaFecha()
 {
     return EntradaSalida::obtenerTodos(' where id_usuario=' . $_SESSION['usuario']->id_usuario . ' and fecha_hora between "' . $_SESSION['turno']->fecha_hora_inicio . '" and CURRENT_TIMESTAMP');
 }
Example #2
0
<html>
    <head>
        <meta charset="UTF-8">
        <title></title>
        <script src="/Abarrotes/library/jquery-1.10.2.min.js"></script>
        <link href="/Abarrotes/library/plantilla_css.css" rel="stylesheet" />
    </head>
    <body>
        
        <?php 
include_once "library/BarraSuperior.php";
include 'Modelos/Venta.php';
include 'Modelos/EntradaSalida.php';
$ventas = Venta::obtenerHastaLaFecha();
$altas = EntradaSalida::obtenerHastaLaFecha();
$total_alta = 0;
$total = 0;
foreach ($altas as $alta) {
    $total_alta += floatval($alta->usuario_producto_cantidad) * $alta->costo;
}
foreach ($ventas as $venta) {
    $total += $venta->total;
}
?>
 
        <div id="cuadrito" class="">
            <h3>Terminar Turno / Corte de Caja</h3>
            <form id="terminarTurno" action="/Abarrotes/Turno/Terminar" method="post">
                <table>
                    <tr>
                        <td>