Develop > Presentation layer > Customize IBM Sales Center > Controls
Declare a composite definition
The layout of the IBM Sales Center dialogs and editors are constructed using configured controls. A configured control is a user interface element that is declared using the controls extension point. The definition of a configured control includes a unique identifier, the type of control, and additional attributes and properties that are specific to the type of control being defined. The control type is used to locate a control factory class that will construct the new configured control. This section explains how to declare a composite definition.
A composite is a control that contains other controls. For example, a login form can be considered as a composite, and all UI elements like user name and password fields are actually controls. The definition of the composite, however, contains the layout details and arrange the controls in form of rows and grids. For example:
<extension point="com.ibm.commerce.telesales.widgets.compositeDefinitions"> <gridCompositeDefinition id="logonInputAreaCompositeDefinition.default" layoutId="standardGridLayout"> <row id="logonInputAreaUserNameRow"> <control controlId="logonUserNameLabel" dataId="requiredLabelGridData"/> <control controlId="logonUserNameField" dataId="requiredFieldGridData"/> </row> ... </gridCompositeDefinition> </extension>When you construct a composite control, the declaration should include a composite definition ID. The composite definition ID is used to locate a composite definition which is then applied to the composite control. The composite definition defines the composite layout and the child controls.
To declare a composite definition:
Procedure
- Create a new plug-in to use for the extensions.
- In the plugin.xml, declare the composite definition using the com.ibm.commerce.telesales.widgets.compositeDefinitions extension point.
- Declare child controls within the composite, if you have not already done so.
Related concepts
User Interface Layouts in the IBM Sales Center
Related tasks
Ovveride vs. extending of composites in IBM Sales Center UI Framework
Move a user interface element between dialogs or editor pages