v0.2.2: surface skipped transactions in the transactions list
This commit is contained in:
@@ -3,6 +3,10 @@
|
||||
All notable changes to Moon Household Budget. Newest first.
|
||||
Generated from changelog.json by release.py — do not edit by hand.
|
||||
|
||||
## 0.2.2 — 2026-06-08
|
||||
|
||||
- Show a banner and filter for transactions skipped during review that still need a category
|
||||
|
||||
## 0.2.1 — 2026-06-06
|
||||
|
||||
- Edit bills inline from the bills page
|
||||
|
||||
8
app.py
8
app.py
@@ -822,6 +822,9 @@ def transactions_view():
|
||||
spending_by_cat = dict(sorted(spending_by_cat.items(), key=lambda x: x[1], reverse=True))
|
||||
week_label = f"Week {current_week_num} ({week_start.strftime('%b %-d')} – {week_end.strftime('%b %-d')})"
|
||||
|
||||
# Count skipped (reviewed but no category, not ignored) for the banner
|
||||
skipped_count = sum(1 for t in transactions if t.get("reviewed") and not t.get("category") and not t.get("ignored"))
|
||||
|
||||
# Optional filters from query string
|
||||
filter_from = request.args.get("from_date", "")
|
||||
filter_to = request.args.get("to_date", "")
|
||||
@@ -840,7 +843,9 @@ def transactions_view():
|
||||
reviewed = [t for t in reviewed if date_parser.parse(t["date"]).date() <= to_d]
|
||||
except Exception:
|
||||
pass
|
||||
if filter_cat:
|
||||
if filter_cat == "__skipped__":
|
||||
reviewed = [t for t in reviewed if not t.get("category") and not t.get("ignored")]
|
||||
elif filter_cat:
|
||||
reviewed = [t for t in reviewed if t.get("category") == filter_cat]
|
||||
if filter_search:
|
||||
q = filter_search.lower()
|
||||
@@ -862,6 +867,7 @@ def transactions_view():
|
||||
week_label=week_label,
|
||||
month_name=cal_mod.month_name[month],
|
||||
year=year, month=month,
|
||||
skipped_count=skipped_count,
|
||||
)
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,11 @@
|
||||
[
|
||||
{
|
||||
"version": "0.2.2",
|
||||
"date": "2026-06-08",
|
||||
"changes": [
|
||||
"Show a banner and filter for transactions skipped during review that still need a category"
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "0.2.1",
|
||||
"date": "2026-06-06",
|
||||
|
||||
@@ -99,6 +99,13 @@
|
||||
</details>
|
||||
{% endif %}
|
||||
|
||||
{% if skipped_count %}
|
||||
<div style="background:#fffbe6;border:1px solid #f5c542;border-radius:var(--radius);padding:0.65rem 1rem;margin-bottom:1rem;display:flex;align-items:center;gap:0.75rem;">
|
||||
<span>⏭️ <strong>{{ skipped_count }} transaction{{ 's' if skipped_count != 1 else '' }}</strong> still need{{ '' if skipped_count != 1 else 's' }} a category (skipped for now).</span>
|
||||
<a href="{{ url_for('transactions_view', category='__skipped__') }}" class="btn btn-ghost" style="font-size:0.82rem;padding:0.2rem 0.65rem;">Show them</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<form method="GET" style="display:flex;gap:0.75rem;align-items:flex-end;flex-wrap:wrap;margin-bottom:1.25rem;background:var(--warm-white);padding:0.85rem 1rem;border-radius:var(--radius);border:1px solid var(--border);">
|
||||
<div style="flex:1;min-width:180px;">
|
||||
<label style="display:block;font-size:0.8rem;margin-bottom:0.2rem;">Search</label>
|
||||
@@ -116,6 +123,7 @@
|
||||
<label style="display:block;font-size:0.8rem;margin-bottom:0.2rem;">Category</label>
|
||||
<select name="category" class="budget-input">
|
||||
<option value="">— all —</option>
|
||||
<option value="__skipped__" {% if filter_cat == '__skipped__' %}selected{% endif %}>⏭️ Needs category</option>
|
||||
{% for cat in categories %}
|
||||
<option value="{{ cat }}" {% if filter_cat == cat %}selected{% endif %}>{{ cat }}</option>
|
||||
{% endfor %}
|
||||
|
||||
Reference in New Issue
Block a user