feat: Implement junior fees dashboard and reconciliation
- Add dual-sheet architecture to pull attendance from both adult and junior spreadsheets. - Introduce parsing rules to isolate juniors (e.g. above '# Treneri', tier 'J'). - Add new endpoints `/fees-juniors` and `/reconcile-juniors` to track junior attendances and match bank payments. - Display granular attendance components showing adult vs. junior practices. - Add fee rule configuration supporting custom pricing exceptions for specific months (e.g. Sep 2025) and merging billing periods. - Add `make sync-2025` target to the Makefile for convenience. - Document junior fees implementation logic and rules in prompts/outcomes. Co-authored-by: Antigravity <antigravity@google.com>
This commit is contained in:
@@ -424,7 +424,9 @@
|
||||
<body>
|
||||
<div class="nav">
|
||||
<a href="/fees">[Attendance/Fees]</a>
|
||||
<a href="/fees-juniors">[Junior Fees]</a>
|
||||
<a href="/reconcile" class="active">[Payment Reconciliation]</a>
|
||||
<a href="/reconcile-juniors">[Junior Reconciliation]</a>
|
||||
<a href="/payments">[Payments Ledger]</a>
|
||||
</div>
|
||||
|
||||
@@ -595,6 +597,7 @@
|
||||
<script>
|
||||
const memberData = {{ member_data| safe }};
|
||||
const sortedMonths = {{ raw_months| tojson }};
|
||||
const monthLabels = {{ month_labels_json| safe }};
|
||||
let currentMemberName = null;
|
||||
|
||||
function showMemberDetails(name) {
|
||||
@@ -633,9 +636,10 @@
|
||||
? `<span style="color: #ffaa00;" title="Overridden from ${originalExpected}">${expected}*</span>`
|
||||
: expected;
|
||||
|
||||
const displayMonth = monthLabels[m] || m;
|
||||
const row = document.createElement('tr');
|
||||
row.innerHTML = `
|
||||
<td style="color: #888;">${m}</td>
|
||||
<td style="color: #888;">${displayMonth}</td>
|
||||
<td style="text-align: center; color: #ccc;">${attendance}</td>
|
||||
<td style="text-align: center; color: #ccc;">${expectedCell}</td>
|
||||
<td style="text-align: center; color: #ccc;">${paid}</td>
|
||||
@@ -664,10 +668,11 @@
|
||||
if (exceptions.length > 0) {
|
||||
exSection.style.display = 'block';
|
||||
exceptions.forEach(ex => {
|
||||
const displayMonth = monthLabels[ex.month] || ex.month;
|
||||
const item = document.createElement('div');
|
||||
item.className = 'tx-item'; // Reuse style
|
||||
item.innerHTML = `
|
||||
<div class="tx-meta">${ex.month}</div>
|
||||
<div class="tx-meta">${displayMonth}</div>
|
||||
<div class="tx-main">
|
||||
<span class="tx-amount" style="color: #ffaa00;">${ex.amount} CZK</span>
|
||||
</div>
|
||||
@@ -686,10 +691,11 @@
|
||||
txList.innerHTML = '<div style="color: #444; font-style: italic; padding: 10px 0;">No transactions matched to this member.</div>';
|
||||
} else {
|
||||
allTransactions.sort((a, b) => b.date.localeCompare(a.date)).forEach(tx => {
|
||||
const displayMonth = monthLabels[tx.month] || tx.month;
|
||||
const item = document.createElement('div');
|
||||
item.className = 'tx-item';
|
||||
item.innerHTML = `
|
||||
<div class="tx-meta">${tx.date} | matched to ${tx.month}</div>
|
||||
<div class="tx-meta">${tx.date} | matched to ${displayMonth}</div>
|
||||
<div class="tx-main">
|
||||
<span class="tx-amount">${tx.amount} CZK</span>
|
||||
<span class="tx-sender">${tx.sender}</span>
|
||||
|
||||
Reference in New Issue
Block a user