<!DOCTYPE html>
<html lang="en">

<head>
	<?php $this->load->view('_partials/head.php'); ?>
</head>

<body>

	<?php //$this->load->view('_partials/navbar.php'); ?>

	<div class="container">
		<h1>List Saldo Akhir</h1>
		<ul>
        <table id='tabelku' width='50%' class='table table-bordered table-hover'>
                    <head>
                    <tr bgcolor='#e5e5e5'>
                     
                    <td align='right'>Id Master</td>
                    <td align='right'>customers_nama </td>
                    <td align='right'>SPO->SO->PKD->SPD </td>
                    </tr>
                    </head>

                    <body>
                    
                    <?php
                    $ctr = -1;
                     foreach ($dukuts as $dukut) :

                     $ctr++;?>
                     <tr bgcolor='#ffffff'>

                                    <?php
                                           $strnomer = ""; 
                                           $id_master="";
                                           $customers_nama="";
                                           $i = 0;
                     foreach($dukut as $row) :
                        $i++;
                        if ($i === 1 ) { 
                        $id_master = $row->id_master;
                        $customers_nama = $row->customers_nama;
                        }
                        $strnomer .= $row->nomer."->";
                        
                     endforeach
                     //tampilkan    
                     ?>
                        <td align='right'>
                        <?=  $id_master ? html_escape($id_master) : "--" ?>		
                         </td>
                         <td align='right'>
                        <?=  $customers_nama ? html_escape($customers_nama) : "--" ?>		
                         </td>
                         <td align='right'>
                        <?=  $strnomer ? html_escape($strnomer) : "--" ?>		
                         </td>
                          
                    
                         </tr>
                         
                    <?php endforeach ?>
                    
                     
                     
                    </body>
</table>

			 
		</ul>
		<?php echo('jmldata produk: <br>'); 
		var_dump($jmldata);
		
		?>

		<div class= "pagination">
			<?=  $this->pagination->create_links(); ?>
			</div>
	</div>

	<?php $this->load->view('_partials/footer.php'); ?>
</body>

</html>
