Show voided transactions in user-entries endpoint #34

Merged
padreug merged 2 commits from feat/show-voided-user-entries into main 2026-06-07 13:38:30 +00:00
Showing only changes of commit 1c89e69030 - Show all commits

feat(api): include voided transactions in user-entries endpoint

The /api/v1/entries/user view was silently dropping any transaction tagged
'voided', so users couldn't see entries that had been rejected against
their accounts. Per the libra reject convention, voided entries keep the
'!' flag and carry a 'voided' tag for audit; clients can use the tag to
style them distinctly. Pending-approval listing still filters voided.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Padreug 2026-06-06 20:47:27 +02:00

View file

@ -486,10 +486,6 @@ async def api_get_user_entries(
if e.get("flag") in _SYNTHETIC_FLAGS: if e.get("flag") in _SYNTHETIC_FLAGS:
continue continue
# Skip voided transactions
if "voided" in e.get("tags", []):
continue
# Extract user ID from metadata or account names # Extract user ID from metadata or account names
user_id_match = None user_id_match = None
entry_meta = e.get("meta", {}) entry_meta = e.get("meta", {})