Introduced in Feature Pack 2

Creating a new tab to display version information

You add a new tab to show the list of versions for your custom object. To define the new tab named "Version", you update your business object properties definition file.

Before you begin

Review the following topic for general instructions on how to add a new tab to an existing Management Center tool: Adding a tab to a properties view.

Procedure

  1. Open WebSphere Commerce Developer and switch to the Enterprise Explorer view.
  2. In the Enterprise Explorer view, expand LOBTools > WebContent > config > commerce > Management_Center_component > propertiesViews; where Management_Center_component is the name of the tool you want to customize.
    Note: All properties view definitions for objects managed by the Management Center are stored in this directory.
  3. Locate the definition that defines the user interface and open this file for editing.
    This file includes the high-level definition of the tabs and definitions that define the contents of each properties view tab.
  4. Determine the location in which you want to place the tab in relation to other properties view tabs for your custom object.
    All tabs are defined within PropertyTabs element.
    • Specify the name and text label for the tab in this tag. Include a comment above this entry for informational purposes.
  5. Save and close the business object properties definition file.

Example

The following code snippet shows how to add a new tab named Version to display version information for a Category.
<!-- This is for supporting version reference of a category -->
1<PropertyTabPane name="manageVersionTab" text="${foundationResources.manageVersionTab}">
<!-- Only show this tab if content versioning feature is enabled, this is not a new object and the object type is CatalogGroup -->
		2<EnablementAndCondition conditionId="categoryManageVersionTabCondition">
			2a<EnablementCondition checkObjectDefinition="true" propertyName="objectType" enablementValue="CatalogGroup" conditionId="categoryManageVersionObjectTypeCondition"/>
			2b<EnablementCondition enablementValue="" propertyName="objectVersionId" conditionId="noObjectVersionIdCondition"/>
			2c<EnablementCondition contextName="contentVersionEnabled" enablementValue="true" conditionId="categoryContentVersionContextValueCondition"/>
			2d<EnablementCondition checkNewObject="true" enablementValue="false" conditionId="categoryContentVersionNewObjectCondition"/>
		</EnablementAndCondition>
<!-- Property Pane: Manage Version. This is an instantiation of the property pane definition which contains versions of this category. -->
		<PropertyPane baseDefinitionName="wcfManageContentVersion"/>
</PropertyTabPane>
  • 1 The propertyPaneTab defines the tab that displays the list of versions.
  • 2 The EnablementAndCondition defines four conditions that must be satisfied in order for the tab to be displayed in the user interface. The conditionId must be unique within this PropertyTabPane element.
  • 2a This first condition verifies that the property pane is displaying a version of the object type.
  • 2b This second condition ensures that the property pane is not displayed when a version of the object is displayed.
  • 2c This third condition ensures that the content versioning feature is enabled.
  • 2d This fourth condition ensures that the object is not a new object. The property pane is not displayed when a new object has been created but has not been saved.