     
<?php $__env->startSection('index-content'); ?>
<style>
  .add-btn{
    width: auto !important;
    height: 31px !important;
    border-radius: 3px !important;
    line-height: 16px !important;
  }
  .table-responsive:nth-child(2) {
        width: 100%;
        height: 76vh;
    }
    .table-responsive:first-child{
        overflow-x: hidden;
    }
    /*th,
    td {
        white-space: nowrap;
    }*/
    table tr td:first-child {
        position: sticky;
        width: 50px;
        left: 0;
        background: #fff;
        color: #000;
        z-index: 9;
    }
    table tr td:nth-child(2) {
        position: sticky;
        left: 65px;
        background: #fff;
        color: #000;
        z-index: 9;
    }
    table tr th:first-child {
        position: sticky;
        width: 50px;
        left: 0;
        /*   background: #fff;*/
        color: #000;
        z-index: 10;
    }
    table tr th:nth-child(2) {
        position: sticky;
        left: 65px;
/*        background: #fff !important;*/
        color: #000;
        z-index: 10;
    }
    tr.table-success {
        position: sticky;
        left: 0;
        z-index: 10;
/*        background: #fff !important;*/
    }
    tr.table-success {
        top: 0px !important;
        position: sticky !important;
    }
    tr.table-warning {
         top: 36px !important;
         position: sticky !important;
    }
    tr.table-warning,
    tr.table-success{
         position: sticky;
         left: 0;
         z-index: 10;
/*         background: #fff !important;*/
    }
    .table-success,
    .table-success > td,
    .table-success > th {
        background-color: #c3e6cb !important;
    }
    .table-warning, .table-warning>td, .table-warning>th {
        background-color: #ffeeba !important;
    }
</style>
<div class="row px-3">
  <section role="main" class="content-body">
    <header class="page-header">
        <div class="row">
          <div class="col-lg-5">
            <h2>Inwards Armsclamps Invoice List</h2>  
          </div>
        
          <div class="col-lg-5">
             <ol class="breadcrumbs">
              <li>
                <a href="<?php echo e(url('index')); ?>">
                  <i class="fa fa-home"></i>
                </a>
              </li>
              <li><a href="<?php echo e('armsclamps_view'); ?>"><span class="active"><?php echo e($district->area_name??"Districts"); ?></span></a></li>
            </ol>
          </div>
          <div class="col-lg-2">
             <div class="add-btn-div">
               <?php if(session()->get('role')==0 ): ?>
            <a href="<?php echo e(url('armsclamps_store')); ?>" class="btn btn-primary add-btn" style="margin-right: 25px;">Add </a>
            <?php endif; ?>
          </div>
          </div>
      </div>
  </header>
      <!-- <header class="page-header">
          <h2>Inwards Armsclamps Invoice List</h2>
      </header> -->
      <div class="row">
        <!-- <div class="col-xs-12">
          <div class="right-wrapper">
            <ol class="breadcrumbs">
              <li>
                <a href="<?php echo e(url('index')); ?>">
                  <i class="fa fa-home"></i>
                </a>
              </li>
              <li><a href="<?php echo e('armsclamps_view'); ?>"><span class="active"><?php echo e($district->area_name??"Districts"); ?></span></a></li>
            </ol>
          </div>
        </div> -->
      <!--   <div class="col-xs-12 mt-3">
          <div>
            <button class="btn btn-primary" onclick="window.history.back()">Back</button>
          </div>
        </div> -->
         
      <div class="col-md-4 mt-2">
      <select class="form-control" id="status_filter">
       
          <option value="1" <?php if(Request::get('status')==1): ?> Selected <?php endif; ?>>Approved</option>
        <!--   <option value="2" <?php if(Request::get('status')==2): ?> Selected <?php endif; ?>>Rejected</option> -->
          <option value="0" <?php if(Request::get('status')==0): ?> Selected <?php endif; ?>>Pending</option>
             <option value="" <?php if(Request::get('status')==""): ?> Selected <?php endif; ?>>All</option>
          
        </select>

      
     
      
    </div>
      </div>


      <!-- start: page -->
          <section class="panel pt-4">
           <!--  <header class="panel-heading mb-5">
              <h4 class="my-0">Inwards Armsclamps Invoice List</h4> 
             <div class="add-btn-div">
               <?php if(session()->get('role')==0 ): ?>
            <a href="<?php echo e(url('armsclamps_store')); ?>" class="btn btn-primary add-btn">Add </a>
            <?php endif; ?>
          </div>

            
            </header>
 -->
             <table class="table table-bordered table-striped mb-none mt-0" id="datatable-default">
               <thead>
                   <tr class="table-success">
                      <th>S.NO</th>
          <th class="text -left">Invoice Number</th>
          <th class="text -left">Received Date</th>
          <th>Arms Dia- 25-mm</th>
          <th>Arms Dia Inner- 32-mm </th>
            <th>Arms Dia inner- 40-mm
</th>
          <th>Clams Set 25-mm </th>
            <th>Clams Set 40- 2-mm</th>
          <th>Clams Set 40- 3-mm</th>
          <th>1C *1.5 sq.mm</th>
          <th>Status</th>
         <!--  <th>Total</th>  -->        
                   </tr>
               </thead>
               <tbody>
               <?php $tw1=0;$tw2=0;$tw3=0;$tw4=0;$tw5=0;$tw6=0;$tw7=0; $sum=0; $i=0;?>
           
            <?php $__currentLoopData = $area_dis; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $list): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>

             <?php $i++;
             $counts=$list['arms_25']+$list['arms_32']+$list['arms_40']+$list['clamps_25']+$list['clamps_42']+$list['clamps_43']+$list['rcv_cbl']
             // $ex_buf_stock=$counts-$list['buffer_stk'];
             ?>
                <tr>
                  <td data-order="<?php echo e($i); ?>"><?php echo e($i); ?></td>
                      <td><a target="blank" href="<?php echo e(url('armsclamps_list')); ?>?id=<?php echo e($list['invoice_number']); ?>&&jilla_id=<?php echo e($list['jilla_id']); ?>"><?php echo e($list['invoice_number']); ?></a></td>
                       <td data-sort="<?php echo e(strtotime( $list['date_of_receiving'] )); ?>"><?php echo e(Carbon\Carbon::parse($list['date_of_receiving'])->format('d/m/Y')); ?></td>
                     <td><?php echo e($list['arms_25']??'0'); ?></td>
                      <td><?php echo e($list['arms_32']??'0'); ?></td>
                       <td><?php echo e($list['arms_40']??'0'); ?></td>
                      <td><?php echo e($list['clamps_25']??'0'); ?></td>
                       <td><?php echo e($list['clamps_42']??'0'); ?></td>
                      <td><?php echo e($list['clamps_43']??'0'); ?></td>
                       <td><?php echo e($list['rcv_cbl']??'0'); ?></td>
                       <td><?php if($list['approve_status']=='1'): ?>
           <?php echo e("Approved"); ?>

           <?php elseif($list['approve_status']=='2'): ?>
           <?php echo e("Rejected"); ?>

           <?php else: ?>
           <?php echo e('Pending'); ?>

         <?php endif; ?> </td>
                      <!-- <td><?php echo e($counts); ?></td> -->


     
                </tr>
               <?php 
       $tw1=$list['arms_25']+$tw1;
       $tw2=$list['arms_32']+$tw2;
       $tw3=$list['arms_40']+$tw3;
       $tw4=$list['clamps_25']+$tw4;
       $tw5=$list['clamps_42']+$tw5;
       $tw6=$list['clamps_43']+$tw6;
       $tw7=$list['rcv_cbl']+$tw7;
       $sum=$sum+$counts; ?>
                                
       <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
     </tbody><tfoot>
       <tr>
        <td data-order="<?php echo e($i); ?>"></td>
         <td><b>Total</b></td>
         <td><b></b></td>
          <td><b><?php echo e($tw1??'0'); ?></b></td>
          <td><b><?php echo e($tw2??'0'); ?></b></td>
          <td><b><?php echo e($tw3??'0'); ?></b></td>
          <td><b><?php echo e($tw4??'0'); ?></b></td>
          <td><b><?php echo e($tw5??'0'); ?></b></td>
          <td><b><?php echo e($tw6??'0'); ?></b></td>
          <td><b><?php echo e($tw7??'0'); ?></b></td>
          <td></td>
         <!--  <td><b><?php echo e($sum??'0'); ?></b></td>  -->    
       </tr>

       <tr>  
     <td data-order="<?php echo e($i); ?>"></td>    
    <td><b>Transferred Total</b></td>
     <td></td>   
      <td><b><?php echo e($inventory_total[0]['arms_25']??'0'); ?></b></td>
          <td><b><?php echo e($inventory_total[0]['arms_32']??'0'); ?></b></td>
          <td><b><?php echo e($inventory_total[0]['arms_40']??'0'); ?></b></td>
          <td><b><?php echo e($inventory_total[0]['clamps_25']??'0'); ?></b></td>
          <td><b><?php echo e($inventory_total[0]['clamps_42']??'0'); ?></b></td>
          <td><b><?php echo e($inventory_total[0]['clamps_43']??'0'); ?></b></td>
          <td><b><?php echo e($inventory_total[0]['rcv_cbl']??'0'); ?></b></td>
    <td></td>
          

</tr>

       <tr>  
     <td data-order="<?php echo e($i); ?>"></td>    
    <td><b>Balance Total</b></td>
     <td></td>   
    <td><b><?php echo e($area_balance[0]['arms_32']); ?></b></td>
    <td><b><?php echo e($area_balance[0]['arms_32']); ?></b></td>
    <td><b><?php echo e($area_balance[0]['arms_40']); ?></b></td>
    <td><b><?php echo e($area_balance[0]['clamps_25']); ?></b></td>
    <td><b><?php echo e($area_balance[0]['clamps_42']); ?></b></td>
    <td><b><?php echo e($area_balance[0]['clamps_43']); ?></b></td>
    <td><b><?php echo e($area_balance[0]['rcv_cbl']); ?></b></td>
    <td></td>
          

</tr>
               
               </tfoot>
           </table>


            <table class="table table-bordered table-striped mb-none mt-0" id="datatable-default">
               <thead>
                <tr class="table-success"><th colspan="10">Move Inventory Armclamps Invoices</th></tr>
                   <tr class="table-warning">

                      <th>S.NO</th>
          <th class="text -left">Invoice Number</th>
          <th class="text -left">Received Date</th>
          <th>Arms Dia- 25-mm</th>
          <th>Arms Dia Inner- 32-mm </th>
            <th>Arms Dia inner- 40-mm
</th>
          <th>Clams Set 25-mm </th>
            <th>Clams Set 40- 2-mm</th>
          <th>Clams Set 40- 3-mm</th>
          <th>1C *1.5 sq.mm</th>
                
                   </tr>
               </thead>
               <tbody>
               <?php $tw1=0;$tw2=0;$tw3=0;$tw4=0;$tw5=0;$tw6=0;$tw7=0; $sum=0; $i=0;?>
           
            <?php $__currentLoopData = $inventory; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $inv): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>

             <?php $i++;
             $counts=$inv['arms_25']+$inv['arms_32']+$inv['arms_40']+$inv['clamps_25']+$inv['clamps_42']+$inv['clamps_43']+$inv['rcv_cbl']
             // $ex_buf_stock=$counts-$inv['buffer_stk'];
             ?>
                <tr>
                  <td data-order="<?php echo e($i); ?>"><?php echo e($i); ?></td>
                       <td><a href="<?php echo e(url('armsmove_inventory_list')); ?>?id=<?php echo e($inv['invoice_number']); ?>"><?php echo e($inv['invoice_number']); ?></a></td>
                       <td data-sort="<?php echo e(strtotime( $inv['date_of_transfer'] )); ?>"><?php echo e(Carbon\Carbon::parse($inv['date_of_transfer'])->format('d/m/Y')); ?></td>
                     <td><?php echo e($inv['arms_25']??'0'); ?></td>
                      <td><?php echo e($inv['arms_32']??'0'); ?></td>
                       <td><?php echo e($inv['arms_40']??'0'); ?></td>
                      <td><?php echo e($inv['clamps_25']??'0'); ?></td>
                       <td><?php echo e($inv['clamps_42']??'0'); ?></td>
                      <td><?php echo e($inv['clamps_43']??'0'); ?></td>
                       <td><?php echo e($inv['rcv_cbl']??'0'); ?></td>
                       
                      <!-- <td><?php echo e($counts); ?></td> -->


     
                </tr>
               <?php 
       $tw1=$inv['arms_25']+$tw1;
       $tw2=$inv['arms_32']+$tw2;
       $tw3=$inv['arms_40']+$tw3;
       $tw4=$inv['clamps_25']+$tw4;
       $tw5=$inv['clamps_42']+$tw5;
       $tw6=$inv['clamps_43']+$tw6;
       $tw7=$inv['rcv_cbl']+$tw7;
       $sum=$sum+$counts; ?>
                                
       <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
     </tbody><tfoot>
       <tr>
        <td data-order="<?php echo e($i); ?>"></td>
         <td><b>Total</b></td>
         <td><b></b></td>
          <td><b><?php echo e($tw1??'0'); ?></b></td>
          <td><b><?php echo e($tw2??'0'); ?></b></td>
          <td><b><?php echo e($tw3??'0'); ?></b></td>
          <td><b><?php echo e($tw4??'0'); ?></b></td>
          <td><b><?php echo e($tw5??'0'); ?></b></td>
          <td><b><?php echo e($tw6??'0'); ?></b></td>
          <td><b><?php echo e($tw7??'0'); ?></b></td>
       
         <!--  <td><b><?php echo e($sum??'0'); ?></b></td>  -->    
       </tr>
               
               </tfoot>
           </table>



            <table class="table table-bordered table-striped mb-none mt-0" >
               <thead>
                 <tr class="table-success"><th colspan="10">Total Quantity By Supplied by</th></tr>
                  <tr class="table-warning">
                      <th>S.NO</th>
          <th class="text -left">Suplied By</th>
          <th>Arms Dia- 25-mm</th>
          <th>Arms Dia Inner- 32-mm </th>
            <th>Arms Dia inner- 40-mm
</th>
          <th>Clams Set 25-mm </th>
            <th>Clams Set 40- 2-mm</th>
          <th>Clams Set 40- 3-mm</th>
          <th>1C *1.5 sq.mm</th>
          
         <!--  <th>Total</th>  -->        
                   </tr>
               </thead>
               <tbody>
               <?php $tw1=0;$tw2=0;$tw3=0;$tw4=0;$tw5=0;$tw6=0;$tw7=0; $sum=0; $i=0;?>
           
            <?php $__currentLoopData = $area_dis_supply; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $list): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>

             <?php $i++;
             $counts=$list['arms_25']+$list['arms_32']+$list['arms_40']+$list['clamps_25']+$list['clamps_42']+$list['clamps_43']+$list['rcv_cbl']
             // $ex_buf_stock=$counts-$list['buffer_stk'];
             ?>
                <tr>
                  <td><?php echo e($i); ?></td>
                      <td><?php echo e($list['suplied_by']); ?></td>
                     <td><?php echo e($list['arms_25']??'0'); ?></td>
                      <td><?php echo e($list['arms_32']??'0'); ?></td>
                       <td><?php echo e($list['arms_40']??'0'); ?></td>
                      <td><?php echo e($list['clamps_25']??'0'); ?></td>
                       <td><?php echo e($list['clamps_42']??'0'); ?></td>
                      <td><?php echo e($list['clamps_43']??'0'); ?></td>
                       <td><?php echo e($list['rcv_cbl']??'0'); ?></td>
                      
                      <!-- <td><?php echo e($counts); ?></td> -->


     
                </tr>
               <?php 
       $tw1=$list['arms_25']+$tw1;
       $tw2=$list['arms_32']+$tw2;
       $tw3=$list['arms_40']+$tw3;
       $tw4=$list['clamps_25']+$tw4;
       $tw5=$list['clamps_42']+$tw5;
       $tw6=$list['clamps_43']+$tw6;
       $tw7=$list['rcv_cbl']+$tw7;
       $sum=$sum+$counts; ?>
                                
       <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
       <tr>
         <td ></td>
         <td><b>Total</b></td>
          <td><b><?php echo e($tw1??'0'); ?></b></td>
          <td><b><?php echo e($tw2??'0'); ?></b></td>
          <td><b><?php echo e($tw3??'0'); ?></b></td>
          <td><b><?php echo e($tw4??'0'); ?></b></td>
          <td><b><?php echo e($tw5??'0'); ?></b></td>
          <td><b><?php echo e($tw6??'0'); ?></b></td>
          <td><b><?php echo e($tw7??'0'); ?></b></td>
      
         <!--  <td><b><?php echo e($sum??'0'); ?></b></td>  -->    
       </tr>
               
               </tbody>
           </table>


            <table class="table table-bordered table-striped mb-none mt-0" >
               <thead>
                 <tr class="table-success"><th colspan="10">Transfer Quantity By Supplied by</th></tr>
                  <tr class="table-warning">
                      <th>S.NO</th>
          <th class="text -left">Suplied By</th>
          <th>Arms Dia- 25-mm</th>
          <th>Arms Dia Inner- 32-mm </th>
            <th>Arms Dia inner- 40-mm
</th>
          <th>Clams Set 25-mm </th>
            <th>Clams Set 40- 2-mm</th>
          <th>Clams Set 40- 3-mm</th>
          <th>1C *1.5 sq.mm</th>
          
         <!--  <th>Total</th>  -->        
                   </tr>
               </thead>
               <tbody>
               <?php $tw1=0;$tw2=0;$tw3=0;$tw4=0;$tw5=0;$tw6=0;$tw7=0; $sum=0; $i=0;?>
           
            <?php $__currentLoopData = $supliedby_inventory_total; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $list): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>

             <?php $i++;
             $counts=$list['arms_25']+$list['arms_32']+$list['arms_40']+$list['clamps_25']+$list['clamps_42']+$list['clamps_43']+$list['rcv_cbl']
             // $ex_buf_stock=$counts-$list['buffer_stk'];
             ?>
                <tr>
                  <td><?php echo e($i); ?></td>
                      <td><?php echo e($list['suplied_by']); ?></td>
                     <td><?php echo e($list['arms_25']??'0'); ?></td>
                      <td><?php echo e($list['arms_32']??'0'); ?></td>
                       <td><?php echo e($list['arms_40']??'0'); ?></td>
                      <td><?php echo e($list['clamps_25']??'0'); ?></td>
                       <td><?php echo e($list['clamps_42']??'0'); ?></td>
                      <td><?php echo e($list['clamps_43']??'0'); ?></td>
                       <td><?php echo e($list['rcv_cbl']??'0'); ?></td>
                      
                      <!-- <td><?php echo e($counts); ?></td> -->


     
                </tr>
               <?php 
       $tw1=$list['arms_25']+$tw1;
       $tw2=$list['arms_32']+$tw2;
       $tw3=$list['arms_40']+$tw3;
       $tw4=$list['clamps_25']+$tw4;
       $tw5=$list['clamps_42']+$tw5;
       $tw6=$list['clamps_43']+$tw6;
       $tw7=$list['rcv_cbl']+$tw7;
       $sum=$sum+$counts; ?>
                                
       <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
       <tr>
         <td ></td>
         <td><b>Total</b></td>
          <td><b><?php echo e($tw1??'0'); ?></b></td>
          <td><b><?php echo e($tw2??'0'); ?></b></td>
          <td><b><?php echo e($tw3??'0'); ?></b></td>
          <td><b><?php echo e($tw4??'0'); ?></b></td>
          <td><b><?php echo e($tw5??'0'); ?></b></td>
          <td><b><?php echo e($tw6??'0'); ?></b></td>
          <td><b><?php echo e($tw7??'0'); ?></b></td>
      
         <!--  <td><b><?php echo e($sum??'0'); ?></b></td>  -->    
       </tr>
               
               </tbody>
           </table>
    
   </section>
 </div>

 <script type="text/javascript">
  $('#status_filter').change(function(){
    var status = $('#status_filter').val(); 
      window.location.href="<?php echo e(url('armsclamps_invoice_list')); ?>?id=<?php echo e($district->id); ?>&&status="+status;
  })
</script>
     <?php $__env->stopSection(); ?>
<?php echo $__env->make('backend.header', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/neefc25/public_html/tgredco.fovea.in/resources/views/backend/armsclamps_invoice_list.blade.php ENDPATH**/ ?>