<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Print</title>
    <!-- Google Font: Source Sans Pro -->
    
<style>
   /*@page  { size: 1000pt 0pt; }*/
   /*embed{*/
   /*    width="1000px";*/
   /*    height="500px";*/
   /*}*/
   th{
       background-color:orange;
       text-align:left;
   }
   td{
       border-left:1px solid grey;
       border-bottom:1px solid grey;
   }
   .logo img{
       width:300px;
       margin:0 auto;
   }
   .table{
      align:center;
      margin-left:150px;
   }
</style>
</head>

<body class="abc">

   <div class="logo">
       
            <center> <img src="<?php  echo $pic ?>"   ></center>
        </div>

          <table  class="table table-bordered table-striped">
                <thead >
                  <tr>
                    <th style="width:30px">Sl.no</th>
              
                    <th>Slip No</th>
                    <th>Supplied Date</th>
                    <th >Customer</th>
                    <th >Invoice No</th>
                    <th >Gallon</th>
                    <th >Bill Amount</th>
                    <th >Payment Date</th>
                     <th >Paid Amount</th>
                     <th>Devided Amount</th>
                      <th>Balance Due</th>
                 </tr>
                </thead>
              <tbody>
        <?php
         $i=1;
         $qty=0;
         $total=0;
         ?>
         <?php $__currentLoopData = $data; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $dat): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
         <?php
       
         $qty=App\Models\SellLines::where('transaction_id','=',$dat['transaction_id'])->sum('quantity');
         $balance = DB::table('transaction_payment')->where('transaction_payment.transaction_id', '=', $dat['tra_id'])->sum('transaction_payment.amount');
            $pay_status = round($dat['bill_amount'], 2) - round($balance, 2);
         $total+=round($dat['devided_amount'],3);
         ?>
     
         <tr>
             <td><?php echo e($i); ?></td>
             <td>SRK :-<?php echo e($dat['transaction_id']); ?></td>
             <td><?php echo e(date('d-m-Y',strtotime($dat['transaction_date']))); ?></td>
             <td><?php echo e($dat['company_name']); ?></td>
             <td><?php echo e($dat['ledger']); ?> - <?php echo e($dat['ledger_value']); ?></td>
             <td><?php echo e($qty); ?></td>
             <td><?php echo e(round($dat['bill_amount'],2)); ?></td>
             <td><?php echo e(date('d-m-Y',strtotime($dat['payment_date']))); ?></td>
             <td><?php echo e($dat['paid_amount']); ?></td>
             <td><?php echo e(round($dat['devided_amount'],2)); ?></td>
             <td><?php echo e(round($pay_status,1)); ?></td>
         </tr>
   
         <?php
         $i++;
         ?>
         <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
         
         
               </tbody>
                      <tfoot>

              <tr class="bg-gray font-17  footer-total">
              <td  ><strong>Total:</strong></td>
              <td></td>
           <td></td><td></td>
           <td></td>
           <td></td>
           <td></td>
           <td></td>
               <td></td>
           <td><?php echo e($total); ?></td>
             <td></td>
              </tr>
              </tfoot>
              </table>




</body>

</html>
<?php /**PATH /home/z7a6qwiy0umc/public_html/srkdiesel-trading.in/resources/views/export_slip_pdf.blade.php ENDPATH**/ ?>