Configuring System Environments > Menu Extension Configuration File
  
Menu Extension Configuration File
The menu extension configuration file defines menus added to the QAD .NET UI outside of the standard programs and functions. By default, the menu extension configuration file is located in TomcatInstallDir/webapps/qadhome/configurations/
default/menus/plugin-menu.xml
.
File Usage
You can define menu extension configuration files for each system environment by placing them in appropriate subdirectories under the /configurations directory, as follows:
TomcatInstallDir/webapps/qadhome/configurations/
config-name/menus/plugin-menu.xml
Where config-name is the system environment name that you select when you log in to the QAD .NET UI.
File Format
The default menu configuration file is located in TomcatInstallDir/webapps/qadhome/configurations/menus/plugin-menu.xml. The file contains hierarchical XML elements. The top-level element is <PluginExtender>.
File Elements
The file includes the following XML elements:
<PluginExtender>
The <PluginExtender> element is the top-level container for the menu extension configuration file.
Contains
<ResourceFile>
<Security>
<Workspaces>
Contained By
Not contained by any other element.
Attributes
 
Name
Description
Default
Req?
provider
Identifies the originator of the menu extensions.
QAD
Yes
key
Specifies the element identifier.
blank
Yes
version
Specifies the version of the menu extension file definition.
1.0.0.0
Yes
Example
<PluginExtender provider="QAD" key="" version="1.0.0.0">
<Security>
The <Security> element contains a set of security constraints.
Contains
<SecurityConstraint>
Contained By
<PluginExtender>
Attributes
N/A
Example
<Security>
<SecurityConstraint key="admin" constraint="allow">
<Role>admin</Role>
<Role>dtadmin</Role>
<Role>qadadmin</Role>
<User>mfg</User>
</SecurityConstraint>
</Security>
<SecurityConstraint>
The <SecurityConstraint> element defines a security constraint key and whether the constraint is to allow or deny access.
Contains
<Role>
<User>
Contained By
<Security>
Attributes
 
Name
Description
Default
Req?
key
Specifies a security constraint key, which identifies a shell menu security group consisting of various roles and users. The menus made available by a given <ShellMenu> element are only available to roles and users within the security constraint key.
admin
Yes
constraint
Define a listing of allowed (allow) or denied (deny) roles or users.
allow
Yes
Example
<Security>
<SecurityConstraint key="admin" constraint="allow">
<Role>admin</Role>
<Role>dtadmin</Role>
<Role>qadadmin</Role>
<User>mfg</User>
</SecurityConstraint>
</Security>
<Role>
The <Role> element specifies a role subject to a security constraint.
Contains
N/A
Contained By
<SecurityConstraint>
Attributes
N/A
Example
<Role>admin</Role>
<User>
The <User> element specifies a user subject to a security constraint.
Contains
N/A
Contained By
<SecurityConstraint>
Attributes
N/A
Example
<User>mfg</User>
<Workspaces>
The <Workspaces> element contains the workspace elements within which the menu extensions are available.
Contains
<Workspace>
Contained By
<PluginExtender>
Attributes
N/A
Example
<Workspaces>
<Workspace key="all" image="" label="">
...
</Workspace>
<Workspaces>
<Workspace>
The <Workspace> specifies the workspace within which the menu extensions are available. By default, the key attribute is set to all so that it applies to all the workspaces.
Contains
<ShellMenus>
Contained By
<Workspaces>
Attributes
 
Name
Description
Default
Req?
image
Specifies the element identifier.
all
Yes
key
Specifies an image for the workspace.
blank
Yes
label
Specifies a label for the workspace.
blank
Yes
Example
<Workspace key="all" image="" label="">
<ShellMenus>
....
</ShellMenus>
<ShellMenus>
....
</ShellMenus>
</Workspace>
<Properties>
The <Properties> element specifies a set of properties. Specifies a property whose type is defined as string, config or label. Properties defined as a label are translated using Label Master. The config properties are resolved using configuration values. The string properties are resolved using any combination of properties or literal strings.
Note: The entries for this element do not typically require any changes by a system administrator. This section is provided for informational purposes only.
Contains
N/A
Contained By
<PluginExtender>
Attributes
N/A
<Property>
The <Property> element under <Properties> specifies a property whose type is defined as string, config or label. Properties defined as a label are translated using Label Master. The config properties are resolved using configuration values. The string properties are resolved using any combination of properties or literal strings.
Note: The entries for this element do not typically require any changes by a system administrator. This section is provided for informational purposes only.
Contains
N/A
Contained By
<Properties>
Attributes
 
Name
Description
Default
Req?
name
The name of the property, which is resolved from an item such as a label defined in the format $(name).
N/A
Yes
value
The value of the property, which the system uses to look up the translation for the name
N/A
Yes
type
The type of the property. The type of the property is set to string by default if type is not included.
string
No
Example
You have defined a shell menu with the label set as ${Processes}, as follows:
<ShellMenus>
<ShellMenu key="process" menuType="application" label "${Processes}">
...
</ShellMenu>
</ShellMenus>
The system resolves the string inside the dollar sign and brackets and identifies the value to look up the label based on an entry for the string in a <Property> element’s name attribute:
<Property name="Processes" value="PROCESSES" type="label"/>
The system looks up the actual string for the label based on the PROCESSES value and displays the string as the label in the QAD .NET UI.
<ShellMenus>
The <ShellMenus> element contains the <ShellMenu> elements that define a particular menu extension.
Contains
<ShellMenu>
Contained By
<Workspace>
Attributes
N/A
Example
<ShellMenus>
<ShellMenu key="process" menuType="application" label="Processes">
...
</ShellMenu>
</ShellMenus>
<ShellMenu>
The <ShellMenu> element specifies a menu extension consisting of one or more <ShellMenuItem> elements.
Contains
<ShellMenuItem>
Contained By
<ShellMenus>
Attributes
 
Name
Description
Default
Req?
key
Specifies the element identifier.
N/A
Yes
menuType
Specifies the menu type, such as application.
N/A
Yes
label
Specifies the name of the menu as it appears on the QAD .NET UI.
N/A
Yes
security
Specifies a security constraint key, defined using the <SecurityConstraint> element.
N/A
No
Example
<ShellMenu key="process" menuType="application" label="Processes">
<ShellMenuItem key="process.0" label="Inventory" image="ProcessMap">
...
</ShellMenuItem>
</ShellMenu>
<ShellMenuItem>
The <ShellMenuItem> specifies a menu item.
Contains
<Command>
<Parameter>
<Property>
Contained By
<ShellMenu>
Attributes
 
Name
Description
Default
Req?
key
Specifies the element identifier.
N/A
Yes
label
Specifies the name of the menu item as it appears on the QAD .NET UI.
N/A
Yes
image
Specifies an image to be associated with the menu item on the QAD .NET UI. A 16x16 pixel icon is returned and converted to a bitmap. There are two methods for resolving image names. The first method uses internal images and can be referenced by a case-insensitive canonical name. If the image cannot be found internally, the image is retrieved from the operating system. Images resolved by the operating system can reference file names or file extensions. For example, image="print" uses the internal print image and image=".pdf" uses the image associated with a PDF file. Standard image keys include the following:
Help
AddTable
OpenFolder
ClosedFolder
Cut
Paste
Copy
Excel
Document
Forms
Mail
Save
Search
Print
PrintPreview
Views
Filter
Chart
N/A
Yes
image
Quantity
Browse
Maint
Report
ProcessMap
Fields
FirstPage
LastPage
PrevPage
NextPage
Load
ClearResults
Go
Add
Remove
Globe
Admin
Bom
BomComponent
NewNode
NewFile
Refresh
Cancel
Home
Favorites
UndoProductStructure
UndoComponent
NewNode
NewFile
Refresh
Cancel
Home
Favorites
UndoProductStructure
UndoComponent
BrowseGrid
ChartDesignIcon
Clear
SaveAs
Edit
MenuCollection
N/A
Yes
image
GoTo
Action
Sort
SortUp*
SortDown*
GridColumnHeaderBackground*
CompanyLogo*
CloseActive*
CloseInactive*
CloseInactiveMouseOver*
CloseActiveMouseOver*
TabHeaderBackground*
TabSeparator*
ChartSampleColumn*
ChartSampleColumn3D*
ChartSampleBar*
ChartSampleBar3D*
ChartSamplePie*
ChartSamplePie3D*
ChartSampleStackedColumn*
ChartSampleStackedColumn3D*
ChartSampleStackedBar*
ChartSampleStackedBar3D*
ActiveTabBackground*
Bullet*
BulletWithTail*
Arrow*
BulletTriangle*
ToolbarBackground*
Delete*
QADIcon*
The asterisk (*) indicates that images that are not 16x16 pixels in size.
N/A
Yes
security
Specifies a security constraint key, defined using the <SecurityConstraint> element.
N/A
No
Examples
The following example adds a process map:
<ShellMenuItem key="process.3" label="Inventory" image="ProcessMap">
<Command type="QAD.Commands.ProcessViewerCommand">
<Parameter value="${DesktopBaseUrl}/ProcessViewer.jsp?ProcessName=Inventory" type="System.Uri,System"/>
<Property name="Text" value="Inventory"/>
</Command>
</ShellMenuItem>
The following example adds Microsoft Notepad:
<ShellMenuItem key="apps.word" label="Notepad" image="notepad.exe">
<Command type="QAD.Commands.ProcessCommand">
<Property name="StartInfo.FileName" value="notepad.exe"/>
</Command>
</ShellMenuItem>
The following adds Microsoft Word:
<ShellMenuItem key="apps.word" label="Word" image=".doc">
<Command type="QAD.Commands.ProcessCommand">
<Property name="StartInfo.FileName" value="WinWord.exe"/>
</Command>
</ShellMenuItem>
The following adds Microsoft Excel:
<ShellMenuItem key="apps.excel" label="Word" image=".xls">
<Command type="QAD.Commands.ProcessCommand">
<Property name="StartInfo.FileName" value="Excel.exe"/>
</Command>
</ShellMenuItem>
The following adds Microsoft Internet Explorer:
<ShellMenuItem key="apps.iexplore" label="WebBrowser" image=".html">
<Command type="QAD.Commands.ProcessCommand">
<Property name="StartInfo.FileName" value="about:blank"/>
</Command>
</ShellMenuItem>
<Command>
The <Command> element specifies a QAD-defined command for a menu item.
Contains
<Parameter>
<Property>
<Method>
Contained By
<ShellMenuItem>
Attributes
 
Name
Description
Default
Req?
type
Specifies the command type as made available by QAD. Examples of command type include the following:
QAD.CommandsProcessCommand
QAD.CommandsProcessViewerCommand
QAD.CommandsStackedCommand
QAD.CommandsWebBrowserCommand
QAD.CommandsPlayListCommand
QAD.CommandsRoleListCommand
N/A
Yes
Example
<Command type="QAD.Commands.ProcessViewerCommand">
<Parameter>
The <Parameter> element specifies a parameter associated with a particular command or method.
Contains
N/A
Contained By
<Command>
<Method>
Attributes
 
Name
Description
Default
Req?
value
Specifies a path or program as required by a <Command> or <Method> element.
N/A
Yes
type
Specifies the value type.
N/A
No
Example
<Parameter value="${DesktopBaseUrl}/ProcessViewer.jsp?ProcessName=Inventory" type="System.Uri,System"/>
<Parameter value="gpbr348.p" type="System.String" />
<Parameter value="popomt.p,sosomt.p" />
<Property>
The <Property> element under <Command> specifies a property associated with a particular command.
Contains
N/A
Contained By
<Command>
Attributes
 
Name
Description
Default
Req?
name
Specifies the name of the property.
N/A
Yes
value
Specifies the value of the property.
N/A
Yes
Example
<Property name="Text" value="Inventory"/>
<Method>
The <Method> element specifies a method associated with a particular command.
Contains
<Parameter>
Contained By
<Command>
Attributes
 
Name
Description
Default
Req?
name
Specifies the name of the method.
N/A
Yes
Example
<Method name="AddMenuItemAliases">
<Parameter value="popomt.p,sosomt.p" />
...
</Method>