Description
The Donation model already stores the donation currency, but several parts of the application still assume that every donation is made in XLM. This results in incorrect notification messages, inaccurate donation summaries, and analytics that do not properly represent multi-currency transactions.
This issue introduces full multi-currency support across the donation workflow, ensuring that the stored currency is respected everywhere donations are displayed, processed, or aggregated. Where values need to be compared or summarized across different currencies, conversion metadata should be stored and used instead of assuming a fixed currency.
Problem Statement
Current implementation issues include:
- Notification messages always display donation amounts as XLM regardless of the actual currency.
- Donation summaries aggregate values without considering different currencies.
- Analytics and reporting assume all donations share the same currency, producing misleading totals.
- No conversion metadata exists for generating normalized metrics or historical reports.
Expected Implementation
Business Logic
- Update donation processing logic to use the currency stored on each
Donation record.
- Remove any hardcoded
"XLM" references from services, helpers, and business logic.
- Ensure all amount formatting functions accept both
amount and currency.
Conversion Metadata
-
Introduce conversion metadata if required for reporting and analytics, such as:
baseCurrency
exchangeRate
convertedAmount
conversionTimestamp
-
Store conversion values at the time of donation to ensure historical reports remain consistent even if exchange rates change.
Notifications
Donation Summaries
Analytics
API Responses
- Verify that donation-related API responses expose the necessary currency information, including any conversion fields if implemented.
- Maintain backward compatibility where possible while extending existing response objects.
Acceptance Criteria
Description
The
Donationmodel already stores the donation currency, but several parts of the application still assume that every donation is made in XLM. This results in incorrect notification messages, inaccurate donation summaries, and analytics that do not properly represent multi-currency transactions.This issue introduces full multi-currency support across the donation workflow, ensuring that the stored currency is respected everywhere donations are displayed, processed, or aggregated. Where values need to be compared or summarized across different currencies, conversion metadata should be stored and used instead of assuming a fixed currency.
Problem Statement
Current implementation issues include:
Expected Implementation
Business Logic
Donationrecord."XLM"references from services, helpers, and business logic.amountandcurrency.Conversion Metadata
Introduce conversion metadata if required for reporting and analytics, such as:
baseCurrencyexchangeRateconvertedAmountconversionTimestampStore conversion values at the time of donation to ensure historical reports remain consistent even if exchange rates change.
Notifications
Update all donation-related notifications to display the correct currency symbol or code.
Examples:
Donation Summaries
Ensure summary endpoints and dashboard widgets correctly handle multiple currencies.
Either:
Prevent direct aggregation of different currencies without conversion.
Analytics
Update analytics queries and reporting logic to:
API Responses
Acceptance Criteria