<div class="content-header">
    <div class="container-fluid">
        <div class="row mb-2">
            <div class="col-sm-6">
                <!-- <h1 class="m-0">Deactive Member </h1> -->
            </div>
            <div class="col-sm-6">
                <ol class="breadcrumb float-sm-right">
                    <li class="breadcrumb-item"><a href="#">Share</a></li>
                    <li class="breadcrumb-item active">Particular Share</li>
                </ol>
            </div>
        </div>
    </div>
</div>




<section class="content">
    <div class="container-fluid">




        <div class="row">

            <section class="col-lg-12 connectedSortable">

                <div class="card">
                    <div class="card-header " style="background-color:#31708e;color:white">
                        <h3 class="card-title">
                        Particular Share Details
                        </h3>
                        <div class="card-tools">
                            <ul class="nav nav-pills ml-auto">
                            </ul>
                        </div>
                    </div>
                    <div class="card-body">
                        <div class="tab-content p-0">

                        <!-- File: src/Template/Articles/edit.ctp -->
                        <h3 class="text-center btn btn-lg btn-light  float-left"><a href="<?php echo base_url(); ?>index.php/Member/share_details">Back</a></h3>
                        <!-- <h1 class="text-center">Particular Thrift</h1><br><br> -->
                        <div class="row">
                            <div class="col-sm-2"></div>
                            <div class="col-sm-8">
                                <?php foreach ($share as $data) : ?>
                                    <center>
                                        <h1>TOTAL SHARE - <?= $data['share_amt']; ?></h1>
                                    </center>
                                    <br>
                                    <table id="table_id" class="table table-striped table-bordered" style="width:100%">
                                        <thead>
                                            <tr>
                                                <th class="text-center">Member No.</th>
                                                <th class="text-center">Member Name</th>
                                                <th class="text-center">Updated on</th>
                                            </tr>
                                        </thead>
                                        <tbody>

                                            <!-- Here's where we iterate through our $articles query object, printing out article info -->


                                            <tr>
                                                <td class="text-center">
                                                    <?= $data['me_no']; ?>
                                                </td>
                                                <td class="text-center">
                                                    <?= $data['mem_name']; ?>
                                                </td>
                                                <td class="text-center">
                                                    <?php if ($data['updated_on'] != "") { ?>
                                                        <?= date('d-m-Y', strtotime($data['updated_on'])); ?>
                                                    <?php } else {
                                                        echo 0;
                                                    }?>
                                                </td>

                                            </tr>
                                            <?php

                                            $total_td += $thrift->thrift_amt;
                                            $tot_td_amt += $thrift->tot_thrift;

                                            ?>
                                        </tbody>
                                        <!-- <tfoot>
                                                <tr>
                                                    <td></td>
                                                    <td class="text-right"><b>Total</b></td>
                                                    <td class="text-right"> <b><?php echo $total_td; ?></b> </td>
                                                    <td class="text-right"> <b><?php echo $tot_td_amt; ?></b></td>
                                                    <td></td>
                                                </tr>
                                            </tfoot> -->
                                    <?php endforeach; ?>
                                    </table>
                                    <table id="table_id" class="table table-striped table-bordered" style="width:100%">
                                        <thead>
                                            <tr>
                                                <th class="text-center">Regular Share Date</th>

                                                <th class="text-center">Regular Share Amount</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            <?php
                                            $total_td = 0;
                                            $tot_td_amt = 0;

                                            ?>
                                            <tr>
                                                <?php foreach ($value as $data) : ?>
                                                    <td class="text-center">
                                                        <?php echo  date("d-m-Y", strtotime($data['paid_on'])); ?>
                                                    </td>
                                                    <td class="text-center">
                                                        <?= $data['share_amt']; ?>
                                                    </td>
                                            </tr>
                                            <?php
                                                    $total_share += $data['share_amt'];

                                            ?>
                                        <?php endforeach; ?>
                                        <tr>
                                            <td class="text-center">
                                                <b>Total</b>
                                            </td>
                                            <td class="text-center">
                                                <b><?= $total_share; ?></b>
                                            </td>



                                        </tr>
                                        </tbody>
                                    </table>

                            </div>
                        </div>

                   

                            
                        </div>
                    </div>
                </div>
        </div>
</section>
</div>
</div>
</section>