Replace billedToTenant boolean with billedTo enum

Migrated from boolean checkbox to enum-based radio buttons for better
flexibility and clarity in tracking bill payment responsibility.

Changes:
- Added BilledTo enum with values 'tenant' and 'landlord'
- Replaced Bill.billedToTenant (boolean) with Bill.billedTo (enum)
- Updated BillEditForm to use radio buttons instead of checkbox
- Updated billActions to handle billedTo enum values
- Updated all display filtering to use enum comparison
- Updated printActions barcode filtering
- Updated translations for radio button labels (en/hr)

The billedTo property is optional for backward compatibility -
undefined values default to BilledTo.Tenant, maintaining current
behavior where only tenant bills are displayed and calculated.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Knee Cola
2025-11-17 13:48:28 +01:00
parent f0ccac3f68
commit 1605eec5fb
9 changed files with 61 additions and 29 deletions

View File

@@ -104,7 +104,9 @@
},
"attachment": "Attachment",
"back-button": "Back",
"billed-to-tenant": "Billed to tenant"
"billed-to-label": "Billed to",
"billed-to-tenant-option": "Tenant",
"billed-to-landlord-option": "Landlord"
},
"location-delete-form": {
"text": "Please confirm deletion of realestate \"<strong>{name}</strong>\".",

View File

@@ -103,7 +103,9 @@
},
"attachment": "Privitak",
"back-button": "Nazad",
"billed-to-tenant": "Plaća podstanar"
"billed-to-label": "Račun plaća",
"billed-to-tenant-option": "Podstanar",
"billed-to-landlord-option": "Vlasnik"
},
"location-delete-form": {
"text": "Molim potvrdi brisanje nekretnine \"<strong>{name}</strong>\".",