.
<?php $__env->startSection("scripts"); ?>

<?php $__env->stopSection(); ?>
<?php $__env->startSection("content"); ?>
	<div class="box">
        <?php echo $__env->make('reports.layout.vertical-header', ["title" => "Reporte de Cierre de Turnos"], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
        <div class="flex flex-row border-b px-5 py-5 text-center ">
            <table class="w-full">
                <thead>
                    <tr>
                        <td class="whitespace-nowrap">
                            <table class="table table-striped text-base">
                                <tbody>
                                    <tr style="border-bottom: 2px solid;">
                                        <td style="padding: 6px 12px; "class="whitespace-nowrap" colspan="1">Turno:</td>
                                        <td style="padding: 6px 12px;" class="whitespace-nowrap" colspan="3"></td>
                                    </tr>
                                    <tr style="border-bottom: 1px solid;">
                                        <td style="padding: 6px 12px;" colspan="3">Ingresos en Efectivo</td>
                                        <td style="padding: 6px 12px;"><?php echo e(number_format($data->totalOnlyCash, 2)); ?> Bs.</td>
                                    </tr>
                                    <tr style="border-bottom: 1px solid;">
                                        <td style="padding: 6px 12px;" colspan="3">Ingresos por Punto de Venta</td>
                                        <td style="padding: 6px 12px;"><?php echo e(number_format($data->totalOnlySalesPoint, 2)); ?>  Bs.</td>
                                    </tr>
                                    <tr style="border-bottom: 1px solid;">
                                        <td style="padding: 6px 12px;" colspan="3">Ingresos por Transferencia / Pago Movil </td>
                                        <td style="padding: 6px 12px;"><?php echo e(number_format($data->totalOnlyBankOperation, 2)); ?>  Bs.</td>
                                    </tr>
                                    <tr style="border-bottom: 1px solid;">
                                        <td style="padding: 6px 12px;" colspan="3">Ingresos por Sistema Prepago </td>
                                        <td style="padding: 6px 12px;"><?php echo e(number_format($data->totalOnlyPrepaid, 2)); ?>  Bs.</td>
                                    </tr>
                                    <tr style="border-bottom: 1px solid;">
                                        <td style="padding: 6px 12px;" colspan="3">Ingresos por Sistema Prepago </td>
                                        <td style="padding: 6px 12px;"><?php echo e(number_format($data->totalOnlyPrepaid, 2)); ?>  Bs.</td>
                                    </tr>
                                    <tr style="border-bottom: 1px solid;">
                                        <td style="padding: 6px 12px;" colspan="3">Total Ingresos en sistemas </td>
                                        <td style="padding: 6px 12px;"><?php echo e(number_format($data->totalbs, 2)); ?> Bs.</td>
                                    </tr>
                                    <tr style="border-bottom: 1px solid;">
                                        <td style="padding: 6px 12px;" colspan="3">Total Ingresos por Boveda </td>
                                        <td style="padding: 6px 12px;"><?php echo e(number_format($data->received, 2)); ?> Bs.</td>
                                    </tr>
                                    <tr >
                                        <td style="padding: 6px 12px;"></td>
                                        <td style="padding: 6px 12px;"></td>
                                        <td style="padding: 6px 12px;"></td>
                                        <td style="padding: 6px 12px;"></td>
                                    </tr>
                                </tbody>
                            </table>
                        </td>
                        <th class="whitespace-nowrap">
                            <table class="table table-striped text-base">
                                <tbody>
                                    <tr class="text-right" style="margin: 40px 0;" rowspan="4">
                                        <td style="padding: 6px 12px;" class="whitespace-nowrap" colspan="1">Lider de Grupo:</td>
                                        <td style="padding: 6px 12px;" class="whitespace-nowrap" colspan="3">__________________________________</td>
                                    </tr>
                                </tbody>
                            </table>
                        </th>
                    </tr>
                </thead>
            </table>
        </div>
        <div class="flex flex-row border-b px-5 py-2 text-center ">
            <table class="w-full">
                <tbody>
                    <tr>
                        <?php
                            $cont = 0;
                        ?>
                        <?php $__currentLoopData = $data->turns; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $turn): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <?php
                                if($cont == 2){
                                    echo "</tr><tr>";
                                    $cont = 0;
                                }
                                $cont++;
                            ?>
                            <td class="whitespace-nowrap" style="border: 1px solid;">
                                <h1 class="text-lg"  style="margin: 10px 12px;">
                                    Numero de Turno <?php echo e($turn->turnNumber); ?>

                                </h1>
                                <div class="overflow-x-auto">
                                    <table class="table table-striped text-base">
                                        <tbody>
                                            <tr style="border-bottom: 1px solid;" class="text-center">
                                                <td style="padding: 6px 12px;" class="whitespace-nowrap" colspan="2">Recaudador</th>
                                                <td style="padding: 6px 12px;" class="whitespace-nowrap" colspan="2"><?php echo e($turn->collector); ?></th>
                                            </tr>
                                            <tr style="border-bottom: 1px solid;">
                                                <td style="padding: 6px 12px;" colspan="3">Numero de Caseta</td>
                                                <td style="padding: 6px 12px;"><?php echo e($turn->workstation); ?></td>
                                            </tr>
                                            <tr style="border-bottom: 1px solid;">
                                                <th class="whitespace-nowrap" colspan="3">Descripción</th>
                                                <th class="whitespace-nowrap">Bs</th>
                                            </tr>
                                            <tr style="border-bottom: 1px solid;">
                                                <td style="padding: 6px 12px;" colspan="3">Total Bs Declarados en el Sistema</td>
                                                <td style="padding: 6px 12px;"><?php echo e(number_format($turn->totalBs, 2)); ?></td>
                                            </tr>
                                            <tr style="border-bottom: 1px solid;">
                                                <td style="padding: 6px 12px;" colspan="3">Ingresos por Prepago </td>
                                                <td style="padding: 6px 12px;"><?php echo e(number_format($turn->paymentMethod[6], 2)); ?></td>
                                            </tr>
                                            <tr style="border-bottom: 1px solid;">
                                                <td style="padding: 6px 12px;" colspan="3">Ingresos por Puntos de Venta </td>
                                                <td style="padding: 6px 12px;"><?php echo e(number_format(($turn->paymentMethod[2] + $turn->paymentMethod[3]), 2)); ?></td>
                                            </tr>

                                            <tr style="border-bottom: 1px solid;">
                                                <td style="padding: 6px 12px;" colspan="3">Ingresos en Efectivo </td>
                                                <td style="padding: 6px 12px;"><?php echo e(number_format($turn->paymentMethod[1], 2)); ?></td>
                                            </tr>
                                            <tr style="border-bottom: 1px solid;">
                                                <td style="padding: 6px 12px;" colspan="3">Ingresos en Transferencia / Pago Movil </td>
                                                <td style="padding: 6px 12px;"><?php echo e(number_format(($turn->paymentMethod[4] + $turn->paymentMethod[5]), 2)); ?></td>
                                            </tr>

                                            <tr style="border-bottom: 1px solid;">
                                                <td style="padding: 6px 12px; font-weight: 600;" >Excedente:</td>
                                                <td style="padding: 6px 12px;"><?php echo e($turn->received - $turn->paymentMethod[1] > 0 ? number_format($turn->received - $turn->paymentMethod[1], 2) : ''); ?></td>
                                                <td style="padding: 6px 12px; font-weight: 600;">Faltante:</td>
                                                <td style="padding: 6px 12px;"><?php echo e($turn->received - $turn->paymentMethod[1] < 0 ? number_format($turn->received - $turn->paymentMethod[1], 2) : ''); ?></td>
                                            </tr>
                                            <tr>
                                                <td style="padding: 6px 12px; font-weight: 600;" >Observaciones: Registro por Boveda: <?php echo e(number_format($turn->received,2)); ?> Bs</td>
                                            </tr>
                                            <tr>
                                                <td style="padding: 6px 12px; font-weight: 600; color: #fff;" ></td>
                                            </tr>
                                        </tbody>
                                    </table>
                                </div>
                            </td >
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                    </tr>
                </tbody>
            </table>
        </div>
        <div class="flex flex-row px-5 pt-4 text-center">
            <div id="piechart"></div>
        </div>
        
    </div>
<?php $__env->stopSection(); ?>


<?php echo $__env->make("reports.layout.layout", \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH C:\xampp\htdocs\sigep-core\resources\views/reports/turns/summary.blade.php ENDPATH**/ ?>