rwadurian/backend/services/contribution-service/src/application/event-handlers
hailin 141db46356 fix(contribution-service): use real contributionPerTree from rate service
Previously, adoptions were synced with hardcoded contributionPerTree=1,
resulting in contribution values like 0.7 instead of the expected 15831.9.

Now the handler fetches the actual contribution rate from ContributionRateService
based on the adoption date, storing values like:
- Personal (70%): 22617 × 70% = 15831.9
- Team Level (0.5%): 22617 × 0.5% = 113.085
- Team Bonus (2.5%): 22617 × 2.5% = 565.425

Note: Historical data may need migration to apply the correct multiplier.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-14 18:01:30 -08:00
..
adoption-synced.handler.ts fix(contribution-service): use real contributionPerTree from rate service 2026-01-14 18:01:30 -08:00
cdc-event-dispatcher.ts fix(contribution): run CDC sync in background to allow API access during sync 2026-01-13 21:50:59 -08:00
referral-synced.handler.ts fix(contribution): 100% sync CDC data and fix calculation trigger timing 2026-01-13 16:55:25 -08:00
user-synced.handler.ts fix(contribution): 100% sync CDC data and fix calculation trigger timing 2026-01-13 16:55:25 -08:00