Using linkx statements
You use linkx
statements in the
config.properties file to define default and additional custom tasks that are
displayed on the Self Service Center navigator. Tasks can be added to the navigator using the
linkx
parameter, where x is an incremental
number, starting with 0, that indicates the task order in the navigator.
You use linkx
statements to add several types of link to the
navigator by using variations of this statement structure:
linkx=id:id, type:linktype,
target:linktarget, label:"linklabel",
description:"linkdescription"
Element | Variables |
---|---|
linkx |
These entries are made in config.properties and are a
replacement for the old format entries for the default menu items, such as
RequestsCatalog=listclf .x is used to indicate the position of an item in the menu, with 0 being the first option. Entries must start with
If
|
id:id |
id is the only required parameter. It is used to uniquely
identify the function that is run with this option. While it is generally a free entry field, there are five predefined values that can be used to add the default navigator options:
If you use a predefined value, any values entered for Note: The Search for Solution option is disabled by default.
The option can be enabled by adding a link statement
linkx=id:Solution . |
image:image_name |
Optional: image_name is the name of the image that is shown
next to the task that is identified by the link x statement. If
no image is specified, a default image for the type is used. New images must be located in the directory: c:\ibm\SMP\maximo\applications\maximo\maximouiweb\webmodule\webclient\javascript\simplesrm\srm\dijit\images\icons |
type:linktype |
Optional: linktype is a predefined value that is used to
identify the type of function that is run by this option:
|
target:linktarget |
Optional: linktarget is used to specify the function that
is run. Depending upon the specified type , the target can be the
name of a dialog, application, Dojo class, or, for web pages, a Launch in Context entry
name. |
label:"linklabel" or
|
Optional: linklabel is used to specify the name of the option, which is shown in bold text on the navigator. You can also use this parameter to change the name of default options. label_key is used to look up localized option names in the locale-specific resource bundle, uiNavigatorStringTable.js. |
description:"linkdescription" or
|
Optional: linkdescription is used to provide a
description of the option, which is shown under the option
desc_key is used to look up localized descriptions in the locale-specific resource bundle, uiNavigatorStringTable.js. |
Using Launch in Context for web pages
To open external web pages from a link
statement, a launch entry is created by
the Launch in Context application. This entry contains, among other things, the target web page
address.
When configuring the launch entry properties, it is recommended that you set the Target Browser Window to _blank or to a named window. The target parameter must be set to a signature option name that is associated to the launch entry. Use the Applications tab in the Security Groups application to grant user and group access privileges to the launch entry sigoption for the Self Service Center application.
Adding Dojo classes
When you define the type
element as script
, you can specify a
Dojo (javascript) class file for the target
parameter.
The class must be copied to the javascript directory. For example:
<drive>:\Program Files\IBM\WebSphere\AppServer\profiles\ctgAppSrv01\installedApps\ctgCell01\MAXIMO.ear\maximouiweb.war\webclient\javascript\com\test\Testscript2.js
As shown in the preceding directory path, for organizational purposes, it is recommended that the class uses a path. For example:
dojo.provide ("com.test.Testscript2.js");
dojo.declare(
"com.test.Testscript2",
null
{
constructor: function(node) {
console.log("Testscript2.ctor - " + node);
},
run: function() {
console.log(Testscript2.run");
alert("in testscript2.run");
}
});
Using localized strings
For link
statements, the optional elements, labelkey
and
desckey
, are used to look up localized strings in the locale-specific resource
bundle, uiNavigatorStringTable.js. Bundles are located in the directory:
c:\ibm\SMP\maximo\applications\maximo\maximouiweb\webmodule\webclient\javascript\simplesrm\srm\dijit\nls
Under the nls directory, you create localized bundles that correspond to the different locales you are using. For example:
nls
├ es
├ fr
├ de
uiNavigatorStringTable.js is placed in the nls folder and in each child folder and contains the locale-specific option name and description. For example, a default bundle file containing English strings:
{
OfferingCatKey: "My Offering Catalog",
OfferingCatDescKey: "Ordering from the Offering catalog",
dummy_: ""
}