Apex Features
Last updated
Last updated
Because some users may query the database directly using our Apex interface, Omnata has provided access to our multi-currency handling classes for Apex users.
These take the form of global classes that can be invoked from code outside of the managed package.
The following classes are used to carry currency-rated data. They are used in place of the standard sObjects (CurrencyType, DatedConversionRate) since these objects may or may not exist depending on the Org configuration.
Field name | Type | Description |
---|---|---|
Field name | Type | Description |
---|---|---|
Contains logic for handling various multi-currency scenarios.
Returns a omnata_sf.ConversionRate object, containing the conversion information for the provided currency code, at the provided effective date.
This information will come from the DatedConversionRate Salesforce object.
Example usage (assumes existing multi-currency configuration in Salesforce):
Returns a omnata_sf.ConversionRateAtDate object, containing the conversion information for the provided currency code
This information will come from the CurrencyTypeSalesforce object.
conversionRate
Decimal
The rate, relative to the corporate rate
decimalPlaces
Integer
The number of decimal places
conversionRate
Decimal
The rate, relative to the corporate rate
decimalPlaces
Integer
The number of decimal places
startDate
Date
The start date of this rateβs effective period
nextStartDate
Date
The date of the day after this rateβs effective date finishes