Removes core balance calculation logic
Migrates balance calculation and inventory tracking to Fava/Beancount, leveraging Fava's query API for all accounting calculations. This simplifies the core module and centralizes accounting logic in Fava.
This commit is contained in:
parent
efc09aa5ce
commit
88ff3821ce
4 changed files with 13 additions and 585 deletions
|
|
@ -4,8 +4,6 @@ Castle Core Module - Pure accounting logic separated from database operations.
|
|||
This module contains the core business logic for double-entry accounting,
|
||||
following Beancount patterns for clean architecture:
|
||||
|
||||
- inventory.py: Position tracking across currencies
|
||||
- balance.py: Balance calculation logic
|
||||
- validation.py: Comprehensive validation rules
|
||||
|
||||
Benefits:
|
||||
|
|
@ -13,16 +11,14 @@ Benefits:
|
|||
- Reusable across different storage backends
|
||||
- Clear separation of concerns
|
||||
- Easier to audit and verify
|
||||
|
||||
Note: Balance calculation and inventory tracking have been migrated to Fava/Beancount.
|
||||
All accounting calculations are now performed via Fava's query API.
|
||||
"""
|
||||
|
||||
from .inventory import CastleInventory, CastlePosition
|
||||
from .balance import BalanceCalculator
|
||||
from .validation import ValidationError, validate_journal_entry, validate_balance
|
||||
|
||||
__all__ = [
|
||||
"CastleInventory",
|
||||
"CastlePosition",
|
||||
"BalanceCalculator",
|
||||
"ValidationError",
|
||||
"validate_journal_entry",
|
||||
"validate_balance",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue