<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Rekap Harian</title>
<link rel="icon" type="image/png" href="<?php echo base_url('assets/') ?>/img/favicon.png"/>
<style type="text/css">
body {
	font-family: Calibri;
	font-size: 8pt;
	color: #000;
}
th, tr, td {
  padding: 2px;
}
</style>
</head>
<body onload="print()">
<table width="250" border="0" align="center">
  <tr>
    <td colspan="4" align="center"><font color="#000000" size="+2" style="text-transform:uppercase"><?php echo $toko->nm_toko; ?></font></td>
  </tr>
  <tr>
    <td align="center">REKAP PENJUALAN</td>
  </tr>
  <tr>
    <td align="center"><?php echo date_indo($tgl) . " " . $waktu ?></td>
  </tr>
  </table>
 
<table width="250" align="center" style="border: bordered border-collapse: collapse;">
  <tr style="border-bottom: 1px solid #ddd;">
    <td align="left"><strong>Keterangan</strong></td>
	<td align="right"><strong>Qty</strong></td>
    <td align="right"><strong>Nilai</strong></td>
  </tr>
  <?php foreach ($trekapd->result() as $key): ?>
  <tr style="border-bottom: 1px solid #ddd;">
    <td>Sales Take Away</td>
	<td><div align="right"><?php echo number_format($key->taqty, 0, ',', '.') ?></div></td>
    <td><div align="right">Rp. <?php echo number_format($key->tarp, 0, ',', '.') ?></div></td>
</tr>
<tr>	
    <td>Sales Dine In</td>
    <td><div align="right"><?php echo number_format($key->diqty, 0, ',', '.') ?></div></td>
	<td><div align="right">Rp. <?php echo number_format($key->dirp, 0, ',', '.') ?></div></td>
 </tr>
 
<tr>	
    <td><b>Total Sales</b></td>
    <td><b><div align="right"><strong><?php echo number_format($key->ttqty, 0, ',', '.') ?></strong></div></b></td>
	<td><b><div align="right"><Strong>Rp. <?php echo number_format($key->ttrp, 0, ',', '.') ?></Strong></div></b></td>
 </tr>
<?php endforeach?>
</table>
<table width="250" align="center" style="border: bordered border-collapse: collapse;">
<?php foreach ($stokd->result() as $key): ?>    
  <tr>
    <td><b>Stok</b></td>
    <td><b><div align="left"><strong><?php echo $key->nm_barang  ?></strong></div></b></td>
    <td><b><div align="right"><strong><?php echo number_format($key->stok, 0, ',', '.') ?></strong></div></b></td>
    
  </tr>
 <?php endforeach?>
 </table>
 <!-- 
 <table width="250" align="center" style="border: bordered border-collapse: collapse;">
<?php foreach ($trekapdp->result() as $key): ?>     
  <tr>
    <td>Promosi </td>
    <td><div align="right"><strong><?php echo number_format($key->diqty, 0, ',', '.') ?></strong></div></td>
	<td><div align="right"><strong>Rp. <?php echo number_format($key->dirp, 0, ',', '.') ?></strong></div></td>
  </tr>
  <?php endforeach?>
</table> -->
<br />  

</body>
</html>