<?php $__env->startSection('content'); ?>
    <!-- Content Wrapper. Contains page content -->
    <div class="content-wrapper">
      <!-- Main content -->
<!-- Main content -->
    <section class="content">

        <!-- /.row -->
        <!-- Main row -->
        <div class="">
            <br><br>
            <?php echo $__env->make('inc.messages', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
          <!-- Left col -->

          <!-- /.Left col -->
          <!-- right col (We are only adding the ID to make the widgets sortable)-->
          <section class="col-lg-12 connectedSortable">

            <!-- Map card -->
            <div class="card">
              <div class="card-header no-border">
                <h3 class="card-title">
                  All Beneficiaries
                </h3>
                <!-- card tools -->

                <!-- /.card-tools -->
              </div>
              <div class="card-body">


                 <br>
              <div class="float-right">

              </div>

              <br><br><br>

              <div class="table-responsive">
                  <table id="" width="100%" class="table-bordered table-striped table-sm dataTable no-footer">
                      <thead>
                      <tr>
                        <th>ID</th>
                        <th>District</th>
                        <th>No. of Beneficiaries</th>
                        <th>Entitlement Amount</th>
                        <th>Service Fee</th>
                        <th>Withdraw Charges</th>
                        <th>Total</th>
                        <th>Quarter</th>
                        <th>Payment Date</th>
                        <th>Financial Year</th>
                        <th>Reference No.</th>
                        <th></th>
                      </tr>
                      </thead>
                      <tbody>
                        <?php $__currentLoopData = $entries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <tr>
                            <td><?php echo e($loop->iteration); ?></td>
                            <td><?php echo e($item->district); ?></td>
                            <td><?php echo e($item->no_of_beneficiaries); ?></td>
                            <td><?php echo e(number_format($item->ent_amount)); ?></td>
                            <td><?php echo e(number_format($item->service_fee)); ?></td>
                            <td><?php echo e(number_format($item->withdraw_charge)); ?></td>
                            <td><?php echo e(number_format($item->total)); ?></td>
                            <td><?php echo e($item->quarter); ?></td>
                            <td><?php echo e($item->pay_date); ?></td>
                            <td><?php echo e($item->fy); ?></td>
                            <td><?php echo e($item->reference); ?></td>
                            <td>
                                <?php
                                            $parameter = Crypt::encrypt($item->id);
                                            ?>
                                <div class="btn-group">
                                    <button type="button" class="btn btn-warning dropdown-toggle" data-toggle="dropdown" aria-expanded="true">
                                      Options
                                    </button>
                                    <div class="dropdown-menu" style="">





                               <!-- <a class="dropdown-item"  href="<?php echo e(URL::to('beneficiaries/edit/'.$parameter )); ?>">Edit</a> -->


                                <!-- <a class="dropdown-item"  href="<?php echo e(URL::to('beneficiaries/view/'.$parameter )); ?>">Preview</a> -->
                                  </div>
                                  </div>

                            </td>
                        </tr>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

                       </tbody>

                    </table>
                    <?php echo $entries->links(); ?>

              </div>
            </div>
            <!-- /.card -->


        </div>
        <!-- /.modal-dialog -->
      </div>
      <!-- /.create modal -->

            <!-- /.card -->
          </section>
          <!-- right col -->
        </div>

    <!-- /.content -->

    <!-- /.create branch modal -->
    <div class="modal fade" id="createB">
        <div class="modal-dialog  mw-100 w-75">
          <div class="modal-content">
            <div class="modal-header">
              <h4 class="modal-title">Make Beneficiary Entry</h4>
              <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                <span aria-hidden="true">&times;</span>
              </button>
            </div>
            <div class="modal-body">
                <div class="card card-primary">
                    <div class="card-header">
                    </div>
                    <!-- /.card-header -->
                    <!-- form start -->
                    <form method="POST" action="/create/beneficiary" role="form" enctype="multipart/form-data" class="form-prevent-multiple-submits">
                      <?php echo csrf_field(); ?>
                      <div class="card-body">
                      <div class="row">
                        <div class="col-md-3">
                            <div class="form-group">
                                <label for="exampleInputPassword1">Select Item Code to Run</label>
                                <br>
                                <select
                                    class="form-control custom-form-inputs select2"
                                    name="item_code"
                                    id="debit_account"

                                    required
                                    >
                                    <option value="">--Select Item Code --</option>
                                    <?php $__currentLoopData = $all_accounts; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $value): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                    <option data-subtext="<?php print_r($value['account_number']);?>" value="<?php print_r($value['account_number']);?>"> <?php print_r($value['name']);?> - <?php print_r($value['account_number']);?></option>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                    </select>
                                <span class="invalid-feedback" id="statementClientError"
                                style="display: none;"></span>
                            </div>
                        </div>
                        <div class="col-md-3">
                            <div class="form-group">
                                <label for="location">Requested By</label>
                                <input type="text" name="requested_by" required class="form-control" id="" placeholder="Enter  Name">
                              </div>
                        </div>
                        <div class="col-md-3">
                            <div class="form-group">
                                <label for="location">Category</label>
                                <select required class="form-control" name="category">
                                    <option selected  >Select Category</option>
                                    <option  value="DLG"  >DLG</option>
                                    <option  value="Staff"  >Staff</option>
                                    <option  value="STT"  >STT</option>
                                    <option  value="Other"  >Other</option>
                                </select>

                              </div>
                        </div>
                        <div class="col-md-3">
                            <div class="form-group">
                                <label for="location">Description</label>
                                <textarea required class="form-control" name="details"></textarea>

                              </div>
                        </div>
                      </div>
                          <h4>Personal Details</h4><hr>
                            <div class="row">
                                <div class="col-md-6">
                                    <div style="border: 2px solid lightgray;padding: 35px;height: 500px;">


                                    <div class="form-group">
                                        <label for="location">Beneficiary Name</label>
                                        <input type="text" name="name" class="form-control" id="" placeholder="Enter  Name">
                                      </div>

                                      <div class="form-group">
                                        <label for="location">Title</label>
                                        <input type="text" name="title" class="form-control" id="" placeholder="Enter Title">
                                      </div>

                                      <div class="form-group">
                                        <label for="employee_-id">Phone Nmuber</label>
                                        <input type="text" name="telephone_number" class="form-control" id="" placeholder="Enter Telephone Number">
                                    </div>

                                    <div class="form-group">
                                        <label for="nin-id">Nationa ID</label>
                                        <input required type="text" name="nin" class="form-control" id="" placeholder="Enter NIN Number">
                                    </div>

                                    <div class="form-group">
                                        <label for="employee_-id">District</label>
                                        <input type="text" name="district" class="form-control" id="" placeholder="Enter District">
                                    </div>




                                    </div>
                                </div>
                                <div class="col-md-6">
                                    <div style="border: 2px solid lightgray;padding: 35px;height: 500px;">

                                        <div class="form-group">
                                            <label for="location">Bank</label>
                                            <input type="text" name="bank" class="form-control" id="" placeholder="Enter Bank">
                                          </div>

                                        <div class="form-group">
                                            <label for="location">Account Number</label>
                                            <input type="number" name="account_number" class="form-control" id="" placeholder="Enter Account Number">
                                        </div>


                                        <div class="form-group">
                                            <label for="employee_-id">Duty Station</label>
                                            <input type="text" name="duty_station" class="form-control" id="" placeholder="Enter Station">
                                        </div>

                                        <div class="form-group">
                                            <label for="employee_-id">Amount </label>
                                            <input type="number" name="amount" class="form-control" id="" placeholder="Enter Amount for Payment">
                                        </div>

                                        <div class="form-group">
                                            <label for="employee_-id">Budget Code </label>
                                            <input type="text" name="budget_code" class="form-control" id="" placeholder="Enter Budget Code">
                                        </div>


                                    </div>


                                </div>

                            </div>
                            <br>


                      </div>
                      <!-- /.card-body -->
                      <div class="card-footer">
                      </div>
                  </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
                <button type="submit" class="btn btn-primary button-prevent-multiple-submits float-right" style="margin-left: 10px;"><i class="fa fa-spinner fa-spin font-icon spinner" aria-hidden="true"></i> Submit</button>
            </div>
          </div>
         </form>
          <!-- /.modal-content -->
        </div>
        <!-- /.modal-dialog -->
      </div>
      <!-- /.create modal -->



    <?php echo $__env->make('inc.copyright', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.dashboard', ['title' => 'Beneficiaries'], \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH D:\xamp\htdocs\esp_manager\resources\views/beneficiaries/index.blade.php ENDPATH**/ ?>