|
|
|
|
@@ -1,132 +1,21 @@
|
|
|
|
|
<!DOCTYPE html>
|
|
|
|
|
<html>
|
|
|
|
|
<head>
|
|
|
|
|
<meta charset="utf-8">
|
|
|
|
|
<title>Daily Sale Payment Report</title>
|
|
|
|
|
<style>
|
|
|
|
|
@page {
|
|
|
|
|
size: A4 landscape;
|
|
|
|
|
margin: 30px;
|
|
|
|
|
}
|
|
|
|
|
body {
|
|
|
|
|
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
|
|
|
|
|
color: #333;
|
|
|
|
|
font-size: 11px;
|
|
|
|
|
margin: 0;
|
|
|
|
|
padding: 0;
|
|
|
|
|
}
|
|
|
|
|
.header-section {
|
|
|
|
|
margin-bottom: 30px;
|
|
|
|
|
border-bottom: 3px solid #00489f;
|
|
|
|
|
padding-bottom: 10px;
|
|
|
|
|
}
|
|
|
|
|
.header-section h1 {
|
|
|
|
|
color: #00489f;
|
|
|
|
|
font-size: 24px;
|
|
|
|
|
font-weight: 300;
|
|
|
|
|
margin: 0;
|
|
|
|
|
text-transform: uppercase;
|
|
|
|
|
letter-spacing: 2px;
|
|
|
|
|
}
|
|
|
|
|
.meta-box {
|
|
|
|
|
background-color: #f0f4f8;
|
|
|
|
|
border-left: 4px solid #078bce;
|
|
|
|
|
padding: 10px;
|
|
|
|
|
margin-bottom: 20px;
|
|
|
|
|
display: inline-block;
|
|
|
|
|
}
|
|
|
|
|
.meta-box p {
|
|
|
|
|
margin: 0;
|
|
|
|
|
font-size: 12px;
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
color: #444;
|
|
|
|
|
}
|
|
|
|
|
.section-title {
|
|
|
|
|
color: #00489f;
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
text-transform: uppercase;
|
|
|
|
|
letter-spacing: 1px;
|
|
|
|
|
margin-bottom: 10px;
|
|
|
|
|
margin-top: 30px;
|
|
|
|
|
}
|
|
|
|
|
table {
|
|
|
|
|
width: 100%;
|
|
|
|
|
border-collapse: collapse;
|
|
|
|
|
margin-bottom: 30px;
|
|
|
|
|
}
|
|
|
|
|
th {
|
|
|
|
|
background-color: #00489f;
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
font-size: 11px;
|
|
|
|
|
text-transform: uppercase;
|
|
|
|
|
padding: 10px 8px;
|
|
|
|
|
text-align: left;
|
|
|
|
|
border: 1px solid #003679;
|
|
|
|
|
}
|
|
|
|
|
td {
|
|
|
|
|
padding: 8px;
|
|
|
|
|
border-bottom: 1px solid #dee2e6;
|
|
|
|
|
border-left: 1px solid #dee2e6;
|
|
|
|
|
border-right: 1px solid #dee2e6;
|
|
|
|
|
color: #333;
|
|
|
|
|
}
|
|
|
|
|
tr:nth-child(even) {
|
|
|
|
|
background-color: #f4f7f9;
|
|
|
|
|
}
|
|
|
|
|
tfoot td {
|
|
|
|
|
background-color: #e0e5ea;
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
color: #00489f;
|
|
|
|
|
border-top: 2px solid #b5c3d0;
|
|
|
|
|
border-bottom: 2px solid #b5c3d0;
|
|
|
|
|
}
|
|
|
|
|
.text-right {
|
|
|
|
|
text-align: right;
|
|
|
|
|
}
|
|
|
|
|
.text-center {
|
|
|
|
|
text-align: center;
|
|
|
|
|
}
|
|
|
|
|
</style>
|
|
|
|
|
</head>
|
|
|
|
|
<body>
|
|
|
|
|
|
|
|
|
|
<table style="width: 100%; border-collapse: collapse; margin-bottom: 20px;">
|
|
|
|
|
<tr>
|
|
|
|
|
<td style="border: none; border-bottom: 3px solid #00489f; padding-bottom: 10px; font-size: 24px; color: #00489f; font-weight: bold; text-transform: uppercase;">
|
|
|
|
|
Daily Sale Payment Report
|
|
|
|
|
</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
<table style="width: 100%; border-collapse: collapse; margin-bottom: 30px;">
|
|
|
|
|
<tr>
|
|
|
|
|
<td style="border: none; border-left: 4px solid #078bce; background-color: #f0f4f8; padding: 10px; font-size: 12px; font-weight: bold; color: #444;">
|
|
|
|
|
REPORT DATE: {{ $report_date }}
|
|
|
|
|
</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
<table style="width: 100%; border-collapse: collapse; margin-bottom: 5px;">
|
|
|
|
|
<tr>
|
|
|
|
|
<td style="border: none; color: #00489f; font-weight: bold; font-size: 14px; text-transform: uppercase;">
|
|
|
|
|
Daily Sales
|
|
|
|
|
</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</table>
|
|
|
|
|
<table>
|
|
|
|
|
<table>
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Date</th>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Reference Number</th>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Cashier</th>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Customer</th>
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">Grand Total</th>
|
|
|
|
|
<th colspan="7" style="font-size: 16px; font-weight: bold;">Daily Sale Payment Report - {{ $report_date }}</th>
|
|
|
|
|
</tr>
|
|
|
|
|
<tr>
|
|
|
|
|
<th colspan="7" style="font-size: 14px; font-weight: bold;">Sales Table (Daily Sale)</th>
|
|
|
|
|
</tr>
|
|
|
|
|
<tr>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Date</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Reference Number</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Cashier</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Customer</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Grand Total</th>
|
|
|
|
|
@foreach($paymentOptions as $option)
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">{{ $option->name }}</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">{{ $option->name }}</th>
|
|
|
|
|
@endforeach
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">Due Amount</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Due Amount</th>
|
|
|
|
|
</tr>
|
|
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
|
|
|
|
@@ -144,11 +33,11 @@
|
|
|
|
|
<td>{{ $sale->reference_no }}</td>
|
|
|
|
|
<td>{{ $sale->cashier }}</td>
|
|
|
|
|
<td>{{ $sale->customer }}</td>
|
|
|
|
|
<td class="text-right">{{ number_format($sale->grand_total, 2) }}</td>
|
|
|
|
|
<td>{{ number_format($sale->grand_total, 2) }}</td>
|
|
|
|
|
@foreach($paymentOptions as $option)
|
|
|
|
|
<td class="text-right">{{ number_format($sale->methods[$option->id] ?? 0, 2) }}</td>
|
|
|
|
|
<td>{{ number_format($sale->methods[$option->id] ?? 0, 2) }}</td>
|
|
|
|
|
@endforeach
|
|
|
|
|
<td class="text-right">{{ number_format($sale->due_amount, 2) }}</td>
|
|
|
|
|
<td>{{ number_format($sale->due_amount, 2) }}</td>
|
|
|
|
|
</tr>
|
|
|
|
|
@php
|
|
|
|
|
$tot_grand += $sale->grand_total;
|
|
|
|
|
@@ -161,36 +50,33 @@
|
|
|
|
|
</tbody>
|
|
|
|
|
<tfoot>
|
|
|
|
|
<tr>
|
|
|
|
|
<td colspan="4" class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">DAILY TOTALS</td>
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($tot_grand, 2) }}</td>
|
|
|
|
|
<td colspan="4" style="font-weight: bold; text-align: right;">Total</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($tot_grand, 2) }}</td>
|
|
|
|
|
@foreach($paymentOptions as $option)
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($option_totals[$option->id], 2) }}</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($option_totals[$option->id], 2) }}</td>
|
|
|
|
|
@endforeach
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($tot_due, 2) }}</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($tot_due, 2) }}</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</tfoot>
|
|
|
|
|
</table>
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
<!-- EMPTY ROW FOR SPACING FOR EXCEL -->
|
|
|
|
|
<table><tr><td style="border: none; padding: 20px;"></td></tr></table>
|
|
|
|
|
<table>
|
|
|
|
|
<tr><td></td></tr>
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
<table style="width: 100%; border-collapse: collapse; margin-bottom: 5px;">
|
|
|
|
|
<tr>
|
|
|
|
|
<td style="border: none; color: #00489f; font-weight: bold; font-size: 14px; text-transform: uppercase;">
|
|
|
|
|
Credit Sale Collections
|
|
|
|
|
</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</table>
|
|
|
|
|
<table>
|
|
|
|
|
<table>
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Original Bill Date</th>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Reference Number</th>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Cashier</th>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Customer</th>
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">Grand Total</th>
|
|
|
|
|
<th colspan="5" style="font-size: 14px; font-weight: bold;">Credit Sale Collections</th>
|
|
|
|
|
</tr>
|
|
|
|
|
<tr>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Original Bill Date</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Reference Number</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Cashier</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Customer</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Grand Total</th>
|
|
|
|
|
@foreach ($paymentOptions as $option)
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">{{ $option->name }}</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">{{ $option->name }}</th>
|
|
|
|
|
@endforeach
|
|
|
|
|
</tr>
|
|
|
|
|
</thead>
|
|
|
|
|
@@ -201,41 +87,38 @@
|
|
|
|
|
<td>{{ $row['reference'] }}</td>
|
|
|
|
|
<td>{{ $row['cashier'] }}</td>
|
|
|
|
|
<td>{{ $row['customer'] }}</td>
|
|
|
|
|
<td class="text-right">{{ number_format($row['grand_total'], 2) }}</td>
|
|
|
|
|
<td>{{ number_format($row['grand_total'], 2) }}</td>
|
|
|
|
|
@foreach ($paymentOptions as $option)
|
|
|
|
|
<td class="text-right">{{ number_format($row['methods'][$option->id] ?? 0, 2) }}</td>
|
|
|
|
|
<td>{{ number_format($row['methods'][$option->id] ?? 0, 2) }}</td>
|
|
|
|
|
@endforeach
|
|
|
|
|
</tr>
|
|
|
|
|
@endforeach
|
|
|
|
|
</tbody>
|
|
|
|
|
<tfoot>
|
|
|
|
|
<tr>
|
|
|
|
|
<td colspan="4" class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">COLLECTION TOTALS</td>
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($creditTotals['grand_total'], 2) }}</td>
|
|
|
|
|
<td colspan="4" style="font-weight: bold; text-align: right;">Total</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($creditTotals['grand_total'], 2) }}</td>
|
|
|
|
|
@foreach ($paymentOptions as $option)
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($creditTotals['methods'][$option->id] ?? 0, 2) }}</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($creditTotals['methods'][$option->id] ?? 0, 2) }}</td>
|
|
|
|
|
@endforeach
|
|
|
|
|
</tr>
|
|
|
|
|
</tfoot>
|
|
|
|
|
</table>
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
<!-- EMPTY ROW FOR SPACING FOR EXCEL -->
|
|
|
|
|
<table><tr><td style="border: none; padding: 20px;"></td></tr></table>
|
|
|
|
|
<table>
|
|
|
|
|
<tr><td></td></tr>
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
<table style="width: 100%; border-collapse: collapse; margin-bottom: 5px;">
|
|
|
|
|
<tr>
|
|
|
|
|
<td style="border: none; color: #00489f; font-weight: bold; font-size: 14px; text-transform: uppercase;">
|
|
|
|
|
Payment Method Summary
|
|
|
|
|
</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</table>
|
|
|
|
|
<table>
|
|
|
|
|
<table>
|
|
|
|
|
<thead>
|
|
|
|
|
<tr>
|
|
|
|
|
<th style="background-color: #00489f; color: #ffffff; font-weight: bold;">Payment Option</th>
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">Sale Amount</th>
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">Received Amount</th>
|
|
|
|
|
<th class="text-right" style="background-color: #00489f; color: #ffffff; font-weight: bold;">Total Amount</th>
|
|
|
|
|
<th colspan="4" style="font-size: 14px; font-weight: bold;">Payment Method Summary</th>
|
|
|
|
|
</tr>
|
|
|
|
|
<tr>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Payment Option</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Sale Amount</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Received Amount</th>
|
|
|
|
|
<th style="font-weight: bold; background-color: #cccccc;">Total Amount</th>
|
|
|
|
|
</tr>
|
|
|
|
|
</thead>
|
|
|
|
|
<tbody>
|
|
|
|
|
@@ -246,10 +129,10 @@
|
|
|
|
|
@endphp
|
|
|
|
|
@foreach ($summaryData as $summary)
|
|
|
|
|
<tr>
|
|
|
|
|
<td><strong>{{ strtoupper($summary['name']) }}</strong></td>
|
|
|
|
|
<td class="text-right">{{ number_format($summary['sale_amount'], 2) }}</td>
|
|
|
|
|
<td class="text-right">{{ number_format($summary['received_amount'], 2) }}</td>
|
|
|
|
|
<td class="text-right">{{ number_format($summary['total_amount'], 2) }}</td>
|
|
|
|
|
<td>{{ $summary['name'] }}</td>
|
|
|
|
|
<td>{{ number_format($summary['sale_amount'], 2) }}</td>
|
|
|
|
|
<td>{{ number_format($summary['received_amount'], 2) }}</td>
|
|
|
|
|
<td>{{ number_format($summary['total_amount'], 2) }}</td>
|
|
|
|
|
</tr>
|
|
|
|
|
@php
|
|
|
|
|
$grand_sale += $summary['sale_amount'];
|
|
|
|
|
@@ -260,13 +143,10 @@
|
|
|
|
|
</tbody>
|
|
|
|
|
<tfoot>
|
|
|
|
|
<tr>
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">GRAND TOTAL</td>
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($grand_sale, 2) }}</td>
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($grand_received, 2) }}</td>
|
|
|
|
|
<td class="text-right" style="background-color: #e0e5ea; font-weight: bold; color: #00489f;">{{ number_format($grand_total, 2) }}</td>
|
|
|
|
|
<td style="font-weight: bold; text-align: right;">Grand Total</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($grand_sale, 2) }}</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($grand_received, 2) }}</td>
|
|
|
|
|
<td style="font-weight: bold;">{{ number_format($grand_total, 2) }}</td>
|
|
|
|
|
</tr>
|
|
|
|
|
</tfoot>
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
|
|
</body>
|
|
|
|
|
</html>
|
|
|
|
|
</table>
|
|
|
|
|
|