<div class="data-table-area">
        <div class="container">
            <div class="row">
                <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
                    <div class="data-table-list">
                        <div class="basic-tb-hd">
                            <h2>Pos Test</h2>
							<?php if (empty($data) == TRUE) { ?>
							<?php if ($this->session->userdata('admin_level') == "User"){ ?>
					 <a href="<?php echo base_URL(); ?>admin/postest/add"> <i class="btn btn-info"> Mulai Postest 	</i></a>
					 <?php } ?>
					  <?php } ?>
						 <?php echo $this->session->flashdata("k");?>
                        <div class="table-responsive">
                            <table id="data-table-basic" class="table table-striped">
                                <thead>
                                    <tr>
                                        <th>Nomor</th>
                                        <th>Pemilik</th>
                                        <th>Alamat</th>
										<th>Nilai</th>
									<?php if ($this->session->userdata('admin_level') == "Admin"){ ?>
                                        <th>Action</th>
                                    <?php } ?>
                                    </tr>
                                </thead>
                                <tbody>
                                    <tr>
                                       <?php 
										if (empty($data)) {
										echo "<tr></tr>";
														} else {
										$no 	= ($this->uri->segment(4) + 1);
										foreach ($data as $b) {
										?> 
										<td><?php  echo $no?></td>
										<td><?php  echo $b->pemilik?></td>
										<td><?php  echo $b->alamat?></td>
										<td><?php  echo $b->total?></td>
										<?php if ($this->session->userdata('admin_level') == "Admin"){ ?>
								<td>  <a href="<?=base_URL()?>admin/postest/edt/<?php echo $b->id?>" </a> <span class="btn btn-success success-icon-notika btn-reco-mg btn-button-mg">edit</span>
									
										<a href="<?=base_URL()?>admin/postest/del/<?php echo $b->id?>" onclick="return confirm('Hapus Data?')" </a> <span class="btn btn-warning warning-icon-notika btn-reco-mg btn-button-mg">delete</span>
									</td>
										<?php } ?>
									</tr>
                                   <?php 
			$no++;
			}
		}
		?>
                                </tbody>
                                
                            </table>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
	
	