Technical Reference: Currency Rate History¶
Entity: CurrencyRateHistoryRecord¶
The entity serves to store a snapshot of the rate in time.
Fields¶
| Name (System) | Type | Description |
|---|---|---|
name |
Varchar | Currency code (e.g., USD, EUR). |
rate |
Float | Exchange rate value against the default currency. |
rateCurrency |
Varchar | Default currency code (e.g., CZK). |
createdAt |
DateTime | Time of record creation. |
Logic (Job)¶
Class: Espo\Modules\CurrencyRateHistory\Classes\Jobs\RecordCurrencyRates
- Loads
defaultCurrencyfrom config. - Loads
currencyListandcurrencyRatesfrom config. - Iterates through currencies.
- Creates
CurrencyRateHistoryRecordentity.
UI Extensions¶
The module extends the currency settings view (views/settings/fields/currency-rates).
It adds logic for selecting from the CurrencyRateHistoryRecord entity and backfilling the input.