Bookshelf Home | Contents | Index | Search | PDF |
Siebel Tools Reference > Pick Applets and Static Picklists > Using the Pick Applet Wizard >
Configuring the Originating Business Component
The originating business component is the business component of the originating applet, as specified in the Business Component property of the Applet object. This business component supplies the data presented in the originating applet. The selection process in the pick applet results in the update of the current record in this business component. Figure 171 shows the detailed definition of the originating business component from Figure 168.
The originating business component has no important property settings that are related to its role in the pick process.
The originating business component has the following important child object definitions:
- Originating field. The originating control displays the data from this field. The originating field has no special role other than being the parent of the pick map object definitions. The Pick List property of the Field specifies the Pick List object. In the Siebel application architecture, pick maps are children of an originating field, rather than the originating business component, in order to support pick applets on more than one field in the business component.
NOTE: The originating field should be a field based on a database column. Pick applets and picklists cannot be associated with read-only fields, including calculated fields.
- Pick maps. Children of the originating field. Each pick map defines a correspondence between a field in the pick business component and one in the originating business component. These correspondences provide the information required to immediately update the current originating business component record with information from the pick business component record when a record is picked. Additionally, one of the pick maps updates the join field, and eventually this causes the join to update the fields in the business component that are dependent on the join.
NOTE: Test your pick map definition after creating it. If the originating field stays the same after choosing a value from the pick applet, you should check the pick map definition for that field.
Each Pick Map object definition has two important properties:
- Field. Identifies a field in the (grandparent) originating business component that is to be populated by data from a field in the pick business component, when the PickRecord method is invoked.
- Pick List Field. Identifies a field in the pick business component that is the source of data for the field in the Field property of the Pick Map object.
Fields in Pick Map objects are updated when the user picks a value from an unbounded picklist. However, fields in Pick Map objects are not updated by the picklist when the user types in a new value (the field the user typed something into is, however, obviously updated with the user's entry).
Typing a new value into an unbounded picklist does not automatically add it to the list of values that can be picked.
Do not define more than one multi-value field in the originating business component that maps to the same destination field in the pick applet's underlying business component (Pick List Field Property). Doing so causes the drop-down arrow for the picklist not to show; as a result, users will not be able to use the picklist.
- Join field. Serves as a foreign key in the join used by the pick applet. Typically, the join field contains Id in its name, such as Account Id or Key Contact Id. It is identified in the Source Field property of the join specification. The join field is one of the fields identified in a pick map object definition. When the user selects a record from the pick applet, the join field is updated (because of the pick map in which it is identified), and this results in the update of all fields that are based on the join.
NOTE: Fields in the originating business component, and the controls or list columns that represent them, initially are updated by the action of the pick maps. The join and join specification do not update the contents of the applet until the user leaves the view and returns to it.
- Join and join specification. The join and join specification object definitions set up the join between the base tables of the originating and pick business components. This join populates those fields in the originating business component that have this join's name in their Join property.
- Fields populated by the pick applet and join. Fields that have the join's name in their Join property are updated when the join field's value changes. Fields that are identified in the Field property of Pick Map object definitions are updated when a selection is made from the pick applet. There is some overlap in the roles of the pick maps and join, in that both generally update the same fields, but the action of the pick maps is immediate and that of the join is somewhat delayed.
That is, even though pick maps can update the display value of joined fields (for example, Account Name) when the user picks a record, pick maps do not physically copy a value to the joined fields—only to the foreign key field (for example, Account Id).
Constraining a Picklist
You can dynamically filter a pick applet to display only records that have field values matching corresponding fields in the originating business component's records. This is called constraining a picklist. For example, a Contact's pick applet invoked from an applet that displays quotes could be configured to display only contacts for the current quote's account.
Pick applet constraints are defined using the Constrain property in the Pick Map object type. For example, if you want to configure a Country picklist to display only states that are part of that country, you need a way to indicate the relationship between each state and its country. You could use the existing Description field in the Picklist Generic BusComp to do this or alternatively, you could extend the table and use a new column. Next, you would need to fill the Description field with valid Country values. Use one of the following methods to accomplish this.
- From the client application, choose Site Map > Application Administration > List Of Values View and populate the Description field with valid Country values.
- From Siebel Tools, choose Account BusComp > State Field > PickMap. Insert a new record in the PickMap list and set the following properties:
After a user selects a value from the Country picklist, the State picklist appears. The values in the State picklist are constrained by the value selected from the Country picklist. The value chosen from the Country picklist is used to filter the values that appear in the State picklist. Only the values where the Description field contains the selected value from the Country picklist will appear in the State picklist.
Pick maps can be of two types: copy pick map or constraint pick maps. Copy pick maps perform the role described in Configuring Originating Business Components: a copy pick map updates the current originating business component record with information from the pick business component. A constraint pick map also configures a mapping between the originating and pick business components, but its purpose is different. It is used to filter the list of records displayed in the pick applet to present only those that have matching values in corresponding fields in the originating and the pick business component.
A pick map is configured as a constraint pick map by setting its Constrain property to TRUE. If FALSE (which is the default), the pick map is a copy picklist.
The pick applet displays only contacts with the same Account, Account Id, and Account Location as the quote. To accomplish this, define a constraint pick map as a child object of the Contact Last Name field (in addition to the various copy pick map object definitions provided in order to implement pick behavior). The presence of this constraint pick map indicates to the system that it is to filter the displayed records in the pick applet.
NOTE: If the constrained field refers to a joined table in the pick business component, the foreign key field must also be constrained. Otherwise, a "This operation is not available for read-only field" error will occur if a new record is created in the pick applet.
Bookshelf Home | Contents | Index | Search | PDF |
Siebel Tools Reference Published: 20 October 2003 |