A merge button on a ribbon tab enables users to navigate through a structure without having to select different views themselves for different item types in a tree. With a merge button, you create a separate item view for each level (item type) of interest and with the click of one button, users can then move through a structure and are presented with a view specific to the item they currently have selected. An example of a suitable use case for a merge button is a very large structure where a graph covering the entire structure is just too large to handle or does not easily zero in on a particular focus area. Separate graph configurations could be set so users can easily zoom in on the different levels of interest in the graph.
- Configuration items for the merge button are created and saved
- The SystemWeaver xID for each configured view that will be included in the merge button definition
- Assignment of the SW Architect role in the database
Obtaining the xID for Each Config Item
Run a search for the configured views using Open item>Other item type.. and selecting the config item type of the definition you are searching for. In the below example, the search is for configured graph definitions.
Then retrieve the xID for the config item by either opening it and copying the xID from the Properties view or copying (Ctrl+C) the item itself in the structure tree and pasting it in to a text editor.
Once you have retrieved all of the XIDs, you are ready to configure the merge button.
A merge button consists of the following elements:
The <MergeButton> tag contains the configuration for one merge button. The following attributes apply:
- caption: is the button label text. This is required.
- image: enables you to add an icon. This is required.
- hint: enables you to add a hint or tool-tip to be displayed when the cursor is positioned on the button. This is optional.
In each MergeButton, include one <ItemView> tag for each config item to be included. The following attributes are required:
- name: is the name of the view (or Extension view) according to the 'Name' column on the Item views tab in Configure the explorer.
- configItem: the xID of the config item.
A merge button does not have to consist of only one type of config item. You can include any of the config types:
<MergeButton caption="Safety " image="104">
<ItemView name="Grid" configItem="x3400000000001CD2"/>
<ItemView name="Report" configItem="x3400000000001D1B"/>
<ItemView name="Chart" configItem="x3400000000001CF3"/>
<MergeButton caption="DAGraphs" image="8"> <ItemView name="XXXGraph" configItem="x3400000000095C0A"/> <ItemView name="XXXGraph" configItem="x340000000009F40F"/> <ItemView name="XXXGraph" configItem="x34000000000956B9"/> </MergeButton>
When users click the DAGraphs button and navigate between the three item types in the tree, the view will update automatically for them.
In the above example, each of the three configItems in the configuration are for different item types in the database. The first ItemView is for the item type of 'Design architecture', the second is for the item type of 'Unallocated design' and the third is for the item type of 'Allocated design' although, in the configuration itself, they do not need to be listed in this order. A merge button should contain only one configItem per item type. If, by chance, there are more than one configItems included for one given item type, the one listed first in the configuration will apply.
Updates to Config Items
Keep in mind that the config items included in the merge button configuration are of a specific version.
If a newer version of a config item is introduced, the xID will need to be updated in the merge button configuration so that it will point to the newer version of the config item view.