<div class="row">
    <div class="col-md-7 my-2">
        <h3 class="fmon">Dashboard</h3>
    </div>
    <div class="col-md-5 my-2">
        <div class="row">
            <div class="col-md-6">
                <a href="<?php echo base_url('Customer'); ?>" class="btn btnC w-100">New Customers</a>
            </div>
            <div class="col-md-6">
                <a href="<?php echo base_url('Customer/approvedcustomer'); ?>" class="btn btnC2 w-100">Approved Customers</a>
            </div>
        </div>
    </div>

</div>

<div class="row">
    <div class="col-md-12">
        <table class="table table-striped" id="tablecustomer">
            <thead class="thead-dark">
                <tr>
                    <th scope="col">Name</th>
                    <th scope="col">Email</th>
                    <th scope="col">Phone</th>
                    <th scope="col">Loyalty Points</th>
                    <th scope="col">Actions</th>
                </tr>
            </thead>
            <tbody>
       
               <?php
                            if (!empty($customerlist)) {
                          
                                $count = 1;
                                foreach ($customerlist['user'] as $id => $user) {
                                 echo "<pre>";
                                 echo "ali";
                                 print_r($user);
                                 echo "</pre>";        
                            ?>
                <tr>
                    <td><?php echo $user['firstName'].' '. $user['lastName'];?></td>
                    <td><?php echo $user['email'];?></td>
                    <td><?php echo $user['phoneNumber'];?></td>
                    <td>1200</td>
                    <td>

                        <div class="dropdown">
                            <button class="btn btnelep2" type="button" data-bs-toggle="dropdown" aria-expanded="false">
                                <img src="./assets/images/ellep.png" alt="">
                            </button>
                            <ul class="dropdown-menu">
                                <li><a class="dropdown-item" href="<?php echo base_url('editcustomer'); ?>">edit</a>
                                </li>
                                <li><a class="dropdown-item" href="#">delete</a></li>

                            </ul>
                        </div>

                    </td>
                </tr>
                <?php }
                            } ?>
              

            </tbody>
        </table>
    </div>
</div>

<script src="<?php echo base_url('assets/js/jquery.min.js'); ?>"></script>
<script>
$(document).ready(function() {
    $('#tablecustomer').DataTable();
});
</script>