- Replace separate [Trezorerie Casa] and [Trezorerie Banca] buttons with single unified [Trezorerie] button in main menu - Add format_treasury_combined_response() formatter showing: - Grand total (Sold Trezorerie) - Casa section with total + all accounts - Banca section with total + all accounts - Compact menu layout: Row 2 [Sold Companie][Trezorerie], Row 3 [Sold Clienti][Sold Furnizori], Row 4 [Evolutie Incasari] - Use Romanian number format (period as thousands separator) Also includes: - Oracle pool: Support both SERVICE_NAME and SID connections (ORACLE_SERVICE_NAME takes priority over ORACLE_SID) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
59 lines
1.3 KiB
Markdown
59 lines
1.3 KiB
Markdown
# Telegram Trezorerie Unification - Quick Summary
|
|
|
|
## What We're Building
|
|
Replace two separate treasury buttons with one unified button showing complete treasury overview.
|
|
|
|
## Key Changes
|
|
|
|
### Menu (Before → After)
|
|
```
|
|
BEFORE:
|
|
Row 2: [Sold Companie] [Trezorerie Casa]
|
|
Row 3: [Trezorerie Banca] [Sold Clienti]
|
|
Row 4: [Sold Furnizori] [Evolutie Incasari]
|
|
|
|
AFTER:
|
|
Row 2: [Sold Companie] [Trezorerie]
|
|
Row 3: [Sold Clienti] [Sold Furnizori]
|
|
Row 4: [Evolutie Incasari]
|
|
```
|
|
|
|
### Message Format (New)
|
|
```
|
|
Sold Total Trezorerie: 20,500 RON
|
|
|
|
Casa
|
|
Sold Total Cash: 5,000 RON
|
|
Conturi de Casa:
|
|
- Casa Lei: 3,000 RON
|
|
- Casa Valuta: 2,000 RON
|
|
|
|
Banca
|
|
Sold Total Banca: 15,500 RON
|
|
Conturi Bancare:
|
|
- BCR RON: 10,000 RON
|
|
- BRD EUR: 5,500 RON
|
|
```
|
|
|
|
## Files to Modify
|
|
|
|
1. **formatters.py** - Add `format_treasury_combined_response()`
|
|
2. **menus.py** - Update `create_main_menu()` layout (lines 234-247)
|
|
3. **handlers.py** - Add `menu:trezorerie` callback case
|
|
|
|
## Backward Compatibility
|
|
|
|
Keep working:
|
|
- `/trezorerie_casa` - shows Casa only
|
|
- `/trezorerie_banca` - shows Banca only
|
|
- `/trezorerie` - shows unified view
|
|
|
|
## Estimated Time
|
|
2.5 hours total (1h coding, 1h testing, 0.5h review)
|
|
|
|
## Testing Focus
|
|
- Grand total = Casa + Banca
|
|
- Menu layout compaction
|
|
- Legacy commands still work
|
|
- Performance footer appears
|