MIF_E31222467/pos-smartphone-fix/resources/views/exports/income_pdf.blade.php

44 lines
1.4 KiB
PHP

<!DOCTYPE html>
<html>
<head>
<title>Laporan Penjualan</title>
<style>
body { font-family: sans-serif; }
table { width: 100%; border-collapse: collapse; margin-top: 20px; }
table, th, td { border: 1px solid black; }
th, td { padding: 6px; text-align: left; }
</style>
</head>
<body>
<h3>Laporan Penjualan - Bulan {{ $bulan }} Tahun {{ $tahun }}</h3>
<table>
<thead>
<tr>
<th>No</th>
<th>Nama Produk</th>
<th>Jumlah Item</th>
<th>Total Bayar</th>
<th>Metode Bayar</th>
<th>Waktu Tanggal</th>
</tr>
</thead>
<tbody>
@foreach ($data as $i => $row)
<tr>
<td>{{ $i + 1 }}</td>
<td>{{ $row->Nama_Produk }}</td>
<td>{{ $row->Jumlah_Item }}</td>
<td>Rp {{ number_format($row->Total_Bayar, 0, ',', '.') }}</td>
<td>{{ $row->Metode_Bayar }}</td>
<td>{{ \Carbon\Carbon::parse($row->Waktu_Tanggal)->format('d-m-Y H:i') }}</td>
</tr>
@endforeach
<tr>
<td colspan="3"><strong>Total</strong></td>
<td colspan="3"><strong>Rp {{ number_format($total, 0, ',', '.') }}</strong></td>
</tr>
</tbody>
</table>
</body>
</html>