Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Table plus
applyColStyleToCelltrue
heading0
columnTypess,s,s,s
heading0
multiplefalse
columnAttributesstyle="background:#e5e7ea;font-weight:bold,,style="background:#e5e7ea;font-weight:bold,
enableSortingfalse


Syntax

i18nText(baseDir, key, language)

Package


Alias


Pkg Usage




Warning
Keep in mind that after modifying properties file you have to restart the JIra.

...

Table plus
applyColStyleToCelltrue
columnTypess,s,s,s
heading0
multiplefalse
enableSortingfalse


Parameter name

Type

Required

Description

baseDir

String

Yes

The relative path to the properties files directory. The path is relative to cprime home.

key

String

Yes

Key for the i18ned message.

language

String

Yes

The language to use for the i18ned text.


Return Type

String

Example

If we have a directory called messages placed under the cprime home directory with the following properties files:

Code Block
runnerLog("UK: " + i18nText("messages", "com.mymessage.test.working", "en_UK"));
runnerLog("US: " + i18nText("messages", "com.mymessage.test.working", "en_US"));
runnerLog("US: " + i18nText("messages", "com.mymessage.test.working", "en"));

runnerLog("Test inexistent key: " + i18nText("message", "com.mymessage.test.inexistent.key", "en_US"));

runnerLog("fr_CH: " + i18nText("messages", "com.mymessage.test.working", "fr_CH"));
runnerLog("fr_FR: " + i18nText("messages", "com.mymessage.test.working", "fr_FR"));

// if the property file does not exists, the value will be returned from the default properties file if exists
runnerLog("Test inexistent property file: " + i18nText("messages", "com.mymessage.test.inexistent.property.file", "ro_RO"));


Note

The properties files should match the folder name and had the properties extension.


See also

Filter by label (Content by label)
showLabelsfalse
max25
showSpacefalse
cqllabel = "" and space = currentSpace ( )
labelsarray_routines