<div class="container-fluid bg-white mt-3 mb-3">
    <div class="row">
        <div class="col-sm-12 pt-3 pb-3">

            <div class="table-responsive">
                <table class="table table-bordered table-striped">
                    <thead>
                        <tr>
                            <th>#</th>    
                            <th>Place</th>
                            <th>Check IN</th>
                            <!--<th>Location</th>-->
                            <th>Check Out</th>
                            <!--<th>Location</th>-->
                        </tr>    
                    </thead>
                    <tbody>
                    <?php
                    $date=date('Y-m-d');
                    $eid=$this->session->userdata('tid');
                    $daily_log=$this->UserModel->daily_log($date,$eid);
                    if($daily_log){
                        $count = 0;    
                        foreach($daily_log as $log){
                            $count=$count + 1;    
                    ?>
                        <tr>
                            <th><?php echo $count;?></th>    
                            <th style="text-transform:uppercase;"><?php echo $log['place'];?></th>
                            <th><?php echo date('h-i-sa',strtotime($log['cat']));?></th>
                            <!--<th>-->
                            <?php
                            $latitude=$log['latd'];
                            $longitude=$log['lotd'];

                            ?>
                            <!--<iframe width="100px" height="100px" src="https://maps.google.com/maps?q=<?php echo $latitude; ?>,<?php echo $longitude; ?>&output=embed" ></iframe>    -->
                            <!--</th>-->
                            <th>
                            <?php
                            if($log['status']==1){ echo date('h-i-sa',strtotime($log['check_out_date_time'])); }
                                else if($log['status']==0){ 
                                    echo "<span class='text-danger'>Pending</span>";    
                                }
                                ?>
                            </th>
                            <!--<th>-->
                            <?php
                            $latd=$log['checkout_latd'];
                            $lotd=$log['checkout_lotd'];
                            if($log['status']==0){
                                // echo "<span class='text-danger'>Pending</span>"; 
                                
                            }else{
                            ?>
                            <!--<iframe width="100px" height="100px" src="https://maps.google.com/maps?q=<?php echo $latd; ?>,<?php echo $lotd; ?>&output=embed" ></iframe>    -->
                            <?php } ?>
                            <!--</th>-->
                        </tr>  
                        <?php
                        }    
                        }

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

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


