(protected) new LocalizationApi()
Functions related to the localization of santedb
- Source:
Members
(static) this.dateFormats
Default date formats
Properties:
Name | Type | Description |
---|---|---|
year |
string | The format of year precision dates |
month |
string | The format of month precision dates |
day |
string | The format of day precision dates |
hour |
string | The format of hour precision dates |
minute |
string | The format of minute precision dates |
second |
string | The format of second precision dates |
year |
||
month |
||
day |
||
hour |
||
minute |
||
second |
- Source:
Methods
(static) getCountry() → {string}
Get the currently configured country code
- Source:
Returns:
The 2 digit ISO country code
- Type
- string
(static) getFormatInformationAsync(locale) → {Promise}
Get localization format information for the specified locale
The localization information contains formatting for currency, formatting for dates, and formatting for numbers
Parameters:
Name | Type | Description |
---|---|---|
locale |
string | The locale for which the format information should be retrieved |
- Source:
Returns:
The promise representing the operation to fetch locale
- Type
- Promise
(static) getLanguage() → {string}
Get the currently configured language
- Source:
Returns:
The ISO language code
- Type
- string
(static) getLocale() → {string}
Get the currently configured locale
- Source:
Returns:
The ISO language code and country code of the application
- Type
- string
(static) getString(stringId, parameters) → {string}
Gets a string from the current user interface localization
Parameters:
Name | Type | Description |
---|---|---|
stringId |
string | The id of the localization string to get |
parameters |
any | The parameters used to substitute the string value |
- Source:
Returns:
The localized string
- Type
- string
(static) setLocale(locale)
Set the current locale of the application
Parameters:
Name | Type | Description |
---|---|---|
locale |
string | The ISO locale (i.e. en-US, en-CA, sw-TZ to set) |
- Source: