You are viewing an old version of this page. View the current version.
Compare with Current View Page History
« Previous Version 16 Next »
This class provides a method that allows working with the localization data.
Instantiates a new empty SimpleMessage class object
Example:
const message = new SimpleMessage();
This method gets a translation of the message specified and returns it in the user's language.
Parameter(s):
Return:
const message = new SimpleMessage(); const messageValue = message.getMessage( 'cannot be blank', 'app', {"column_translated_title": "Field Name", "column_name": "field_name"} ); ss.info(messageValue); // Info: The "{column_translated_title}" [{column_name}] field is mandatory.
And as example, the message settings are as follows:
To know more about messages configuration, please refer to relevant documentation section dedicated to messages and interface localization.
const message = new SimpleMessage(); const localizedMessage = message.getMessage('Spaces are not allowed in a table name'); ss.addErrorMessage(localizedMessage);