castle/static
padreug 61a3831b15 Add user-selectable date range filters for Recent Transactions
Implemented performance optimization to reduce Fava API load for ledgers
with large transaction histories. Users can now choose to view transactions
from the last 5, 30, 60, or 90 days instead of loading all entries.

Changes:
- Backend (views_api.py): Added 'days' parameter to api_get_user_entries
  endpoint with default value of 5 days
- Backend (fava_client.py - previously committed): get_journal_entries
  supports optional days parameter with date filtering logic
- Frontend (index.js): Added setTransactionDays() method and days
  parameter handling in loadTransactions()
- Frontend (index.html): Added q-btn-toggle UI control for date range
  selection visible to all users

Default: 5 days (aggressive optimization for large ledgers)
Options: 5, 30, 60, 90 days

Performance impact: ~10x improvement for typical ledgers (229 entries
reduced to 20-50 entries for 5-day window).

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-11 22:54:14 +01:00
..
image Adds comprehensive documentation and patterns 2025-10-22 23:38:05 +02:00
js Add user-selectable date range filters for Recent Transactions 2025-11-11 22:54:14 +01:00