Configuration Guide for Siebel Offline Client for Life Sciences > Extending the Basic Content in the Sales Application >
Adding a Drag-and-Drop Association
This topic describes how to add a drag-and-drop association between applets by adding a predefined example. To add a drag-and-drop association
- Start Oracle JDeveloper.
- In the Application Navigator window, expand the Projects option, and then click appletsdefn.xml.
- In the appletsdefn.xml Structure window, expand AppletData, and then:
- Find and expand APPLET - Available Samples Tiled Applet. This applet contains a list of the available samples, which can be accessed using the Samples tab on the Contact Call page.
In Property Inspector, make sure that DRAG_ENABLED is set to true. This attribute sets up drag support on the source applet.
- Find and expand APPLET - Samples Drop List Applet. This applet contains a list of the samples dropped that are associated with a call, which can be accessed using the Samples tab.
- In Property Inspector, make sure that DROP_ENABLED is set to true. This attribute sets up drop support on the target applet.
- Expand the APPLET_USER_PROPS node, and select the APPLET_USER_PROP - Lookup:SampleInventory user property.
The VALUE attribute, ProductId, indicates which pickmaps are called when that entity is dropped. In this case, the pickmap specified is for ProductId. A pickmap copies a field's value from a source object's record to the current object's record when the source object's record is picked or dropped.
- Expand the TEMPLATE - A_T_Lightweight_List_Half_Width node, then TEMPLATE_ITEM - ProductID, and then PICKMAPS.
To set up a drop on an applet, a pickmap must be defined for the Foreign key ID field and also for any joined-in fields displayed in the drop applet. In this case, a pickmap is defined for Product Id and Product Name.
- Return to APPLET_USER_PROPS, and select the APPLET_USER_PROP - OnDrop:SampleInventory user property.
The VALUE attribute, Insert, indicates which operation must be triggered when a drag-and-drop action occurs. In this case, an insert operation must be triggered.
The VALUE attribute setting for the OnDrop:SampleInventory user property can also be an expression if an insert operation and update operation are required. For example, you may want to update a contact record that already exists in the target applet or you may want to create a new one. If so, then use the following expression:
Expr:IIF([ContactId]="","Copy","Update")
|