
<?php $__env->startSection('main-content'); ?>
    <main>
        <div class="container-fluid">
            <h2 class="mt-5 mb-4">Operator Report</h2>
           <form id="formSubmit" action="<?php echo e(url('/operator/report')); ?>" method="get">
            <?php echo csrf_field(); ?>
            <div class="row">
            <div class="col-md-3">
                    <div class="form-group">
                        <label for="">From Date</label>
                        <input type="date" id="from_date" class="form-control" name="from_date" value="<?php echo e(Request::get('from_date')); ?>" required>
                    </div>
            </div>
               <div class="col-md-3">
                <div class="form-group">
                            <label for="">To Date</label>
                            <input type="date" id="to_date" name="to_date" class="form-control" value="<?php echo e(Request::get('to_date')); ?>" required>
                        </div>
                 </div>
                 
                 <div class="col-md-3">
                    <div class="form-group">
                        <input type="submit" class="btn btn-primary" value="Search" style="margin-top:25px;">
                        <input type="hidden" name="download_pdf" id="download_pdf" value="">
                        <button type="button" onclick="downloadPDF()" class="btn btn-primary" style="margin-top:25px;margin-left:25px;"><i class="fa fa-download"></i> Download PDF</button>  
                    </div>
                 </div>
            </div>
            </form>
            <div class="row">
              
                <div class="col-md-12">
                    <div class="card card-primary">
                        <div class="card-header">
                            <h6 class="card-title">
                                Report
                            </h6>
                          
                        </div>
                        <div class="card-body" id="demo">
                            <div class="table-responsive">
                                <table class="table table-bordered table-striped" width="100%" cellspacing="0">
                                <thead>
                                        <tr>
                                            <th>State</th>
                                            <th><?php echo e(!empty($data)?$data['State']:''); ?></th>
                                            <th>District</th>
                                            <th><?php echo e(!empty($data)?$data['District']:''); ?></th>
                                            <th>Branch ID</th>
                                            <th><?php echo e(!empty($data)?$data['Branch_Code']:''); ?></th>
                                        </tr>
                                        <tr>
                                            <th>Operator ID</th>
                                            <th>Operator Name</th>
                                            <th>Station Code</th>
                                            <th colspan="2">Registrar Code</th>
                                            <th>EA Code</th>
                                        </tr>
                                        <tr>
                                            <th><?php echo e(!empty($data)?$data['Operator_ID']:''); ?></th>
                                            <th><?php echo e(!empty($data)?$data['Operator_Name']:''); ?></th>
                                            <th><?php echo e(!empty($data)?$data['Station_Code']:''); ?></th>
                                            <th colspan="2"><?php echo e(!empty($data)?$data['Registrar_Code']:''); ?></th>
                                            <th><?php echo e(!empty($data)?$data['EA_Code']:''); ?></th>
                                        </tr>
                                        <tr>
                                            <th colspan="6"></th>
                                        </tr>
                                        <tr>
                                            <th>New Enrolments</th>
                                            <th>Mandatory Biometric Updates</th>
                                            <th>Demographic Update</th>
                                            <th colspan="3">Biometric Update</th>
                                            <!-- <th>Demographic with Biometric Update</th> -->
                                        </tr>
                                        <tr>
                                            <th><?php echo e(!empty($data)?$data['New_Enrolment']:''); ?></th>
                                            <th><?php echo e(!empty($data)?$data['Mandatory_Biometric_Updates']:''); ?></th>
                                            <th><?php echo e(!empty($data)?$data['Demographic_Update']:''); ?></th>
                                            <th colspan="3"><?php echo e(!empty($data)?$data['Biometric_Update']:''); ?></th>
                                            <!-- <th><?php echo e(!empty($data)?$data['Demographic_with_Biometric_Update']:''); ?></th> -->
                                        </tr>
                                        <tr >
                                            <th rowspan="7" colspan="2"></th>
                                            <th colspan="2">Amount Collected (A)</th>
                                            <th colspan="2">Amount Collected (B)</th>
                                        </tr>
                                        <tr>
                                            <th colspan="2"><?php echo e(!empty($data)?$data['AmountCollected_A']:''); ?></th>
                                            <th colspan="2"><?php echo e(!empty($data)?$data['AmountCollected_B']:''); ?></th>
                                        </tr>
                                        <tr>
                                            <th colspan="3">Total Amount(X)</th>
                                            <th><?php echo e(!empty($data)?$data['Total_Amount_X']:''); ?></th>
                                        </tr>
                                        <tr>
                                            <th colspan="4"></th>
                                        </tr>
                                        <tr>
                                            <th colspan="3">Total Amount (Y)</th>
                                            <th><?php echo e(!empty($data)?$data['bankDepositAmt']:""); ?></th>
                                        </tr>
                                        <tr>
                                            <th colspan="3">PENDANCY</th>
                                            <th><?php echo e(!empty($data)?($data['Total_Amount_X']-$data['bankDepositAmt']):''); ?></th>
                                        </tr>
                                        <tr>
                                            <th></th>
                                            <th colspan="2"></th>
                                            <th></th>
                                        </tr>
                                       
                                    </thead>
                                    
                                </table>
                            </div>
                        </div>
                        <!-- /.card-body -->
                    </div>
                    <!-- /.card -->

                    <!-- end -->
                </div>
            </div>

        </div>
    </main>
    <script src="https://code.jquery.com/jquery-3.7.1.js"></script>
    <script>
        function downloadPDF(){
            if(from_date=="" || to_date==""){
                alert('Please select date..');
                return false;
            }
            $('#download_pdf').val('download');
            $('#formSubmit').submit();
        }
    </script>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('operator.layouts.master', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/aks5g/public_html/aadhar.aks.5g.in/resources/views/operator/report.blade.php ENDPATH**/ ?>