Commit Graph

3 Commits

Author SHA1 Message Date
d809e23b5c feat(core): Add States, CurrencyRates, and UoM conversion (MGN-005)
- State entity and service with CRUD operations
- CurrencyRate entity and service with conversion support
- UoM conversion methods (convertQuantity, getConversionTable)
- New API endpoints for states, currency rates, UoM conversions
- Updated controller and routes

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-18 08:57:21 -06:00
6054102774 [BACKEND] feat: EPIC-001 & EPIC-002 - Core module completion and entity consolidation
EPIC-001: Complete Core Module
- Add PaymentTerm entity with multi-line support (30/60/90 days, early payment discounts)
- Add PaymentTerms service with calculateDueDate() functionality
- Add DiscountRule entity with volume/time-based conditions
- Add DiscountRules service with applyDiscounts() and rule combination logic
- Add REST endpoints for payment-terms and discount-rules in core module
- Register new entities in TypeORM configuration

EPIC-002: Entity Consolidation
- Add inventoryProductId FK to products.products for linking to inventory module
- Consolidate Warehouse entity in warehouses module as canonical source
- Add companyId and Location relation to canonical Warehouse
- Update inventory module to re-export Warehouse from warehouses module
- Remove deprecated warehouse.entity.ts from inventory module
- Update inventory/warehouses.service.ts to use canonical Warehouse

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-18 05:13:34 -06:00
12fb6eeee8 Initial commit - erp-core-backend 2026-01-04 06:40:14 -06:00