{% extends "base.html" %}
{% block title %}Cash Summary{% endblock %}
{% block content %}
<h2>💵 Cash Book Balance Summary</h2>
<div class="alert alert-success"><b>Total Business Balance:</b> LKR {{ '%.2f'|format(total.balance or 0) }}</div>
<table class="table table-bordered table-striped"><thead><tr><th>Payment Method</th><th>Credits</th><th>Debits</th><th>Balance</th></tr></thead><tbody>{% for r in rows %}<tr><td>{{ r.payment_method }}</td><td>{{ '%.2f'|format(r.credits or 0) }}</td><td>{{ '%.2f'|format(r.debits or 0) }}</td><td><b>{{ '%.2f'|format(r.balance or 0) }}</b></td></tr>{% else %}<tr><td colspan="4" class="text-center">No cash book entries.</td></tr>{% endfor %}</tbody></table>
{% endblock %}
