Siebel CRM Desktop for IBM Notes Administration Guide > Customizing Siebel CRM Desktop > Process of Adding Custom Objects >
Creating the Custom Object
This task is a step in Process of Adding Custom Objects. In this topic, to add a new object to IBM Notes, you describe the structure of the object and then create mappings between fields, lists, and so on. You make these customizations in the Ln_siebel_basic_mapping.xml file. To create the custom object
- Use an XML editor to open the Ln_siebel_basic_mapping.xml file.
For more information, see Files in the Customization Package.
- Specify the name of the custom object. You add the following code to the Ln_siebel_basic_mapping.xml file:
<type id="Action" form="sblActivity"> </type>
This example code defines sblAction as the form to display for this object. You specify the form layout later.Create a set of fields for the custom object.
For more information, see Creating a Set of Fields for the Custom Object.
- Specify intersection objects for many-to-many relationships.
For more information, see Specifying the Many-To-Many Relationships.
- Specify the lists.
For more information, see Specifying the List.
Creating a Set of Fields for the Custom Object
This topic describes how to create a set of fields for the custom object. In this example, you configure CRM Desktop to synchronize the Main Phone Number and the Currency Code fields of the Account form with the corresponding data for these fields that resides on the Siebel Server. To create a set of fields for the custom object
- Open IBM Domino Designer, and then add a new Main Phone Number field and a new Currency Code field on the Account form.
For more information, see Opening IBM Domino Designer.
- Use an XML editor to open the Ln_siebel_basic_mapping.xml file.
- Locate the following code:
<type id="Account" form="sblAccount">
- Add the following code immediately under the code you located in Step 3.
<field ver="1" id="Description" lotus_field="Description" /> <field ver="1" id="Type" lotus_field="CRMDActionType" /> <field ver="1" id="Priority" lotus_field="Priority" /> <field ver="1" id="Primary Owner Id" lotus_field="CRMDEmployeeId" /> <field ver="1" id="Planned Start" lotus_field="StartDateTime" /> <field ver="1" id="Planned Completion" lotus_field="EndDateTime" /> <field ver="1" id="Comments" lotus_field="Comments" /> <field ver="1" id="Account Id" lotus_field="CRMDAccountId" /> <field ver="1" id="Opportunity Id" lotus_field="CRMDOpportunityId" />
- Use an XML editor to open the siebel_meta_info.xml file.
- Locate the following code:
<object TypeId='Account' Label='#obj_account' LabelPlural='#obj_account_plural' UpsertBusObjCacheSize='0' EnableGetIDsBatching='true' IntObjName='CRMDesktopAccountIO' SiebMsgXmlElemName='Account' SiebMsgXmlCollectionElemName='ListOfCRMDesktopAccountIO'>
- Add the following code immediately under the code you located in Step 6.
<field Name='Main Phone Number' Label='#fld_account@main_phone_number' DataType='DTYPE_PHONE' IOElemName='MainPhoneNumber' />
<field Name='Currency Code' Label='Currency Code' DataType='DTYPE_ID' IsFilterable='no' IsRefObjId='yes' RefObjTypeId='Currency' IOElemName='CurrencyCode' />
Fields That Siebel CRM Desktop Uses for the Custom Object
Table 13 describes the fields you create for this example.
Table 13. Fields That Siebel CRM Desktop Uses for the Custom Object
|
|
|
|
Description |
Description |
Description |
Text |
Type |
Type |
CRMActionType |
Picklist |
Priority |
Priority |
Priority |
Picklist |
Owner |
Primary Owner Id |
CRMEmployeeId |
Lookup |
Account |
Account Id |
CRMAccountId |
Lookup |
Opportunity |
Opportunity Id |
CRMOpportunityId |
Lookup |
Contacts |
No field on this object |
Not applicable |
MVG |
Employee |
No field on this object |
Not applicable |
MVG |
Planned Start |
Planned Start |
StartDateTime |
datetime |
Planned Completion |
Planned Completion |
EndDateTime |
datetime |
Comments |
Comment |
Comments |
Textarea |
Specifying the Many-To-Many Relationships
You do not specify many-to-many relationships in Step . A many-to-many relationship exists between contacts and activities, and between employees and activities. You must specify more objects that contain links to activity and contact, or activity and employee. The remaining description for a many-to-many relationship is the same as for other objects where you specify the object name and object fields. This object can also include a field that indicates if this intersection record is a primary record or not a primary record. To specify the many-to-many relationships
- Open IBM Domino Designer, open the Account form, and then create the MVG button.
For more information, see Opening IBM Domino Designer.
- Use an XML editor to open the Ln_siebel_basic_mapping.xml.
- Add the following code:
<type id="Account.Contact.Association"> <field id="ContactId" ver="1"> <reader> <lotus_std> <lotus_field id="CRMDRightId"/> <convertor> <binary_hexstring/> </convertor> </lotus_std> </reader> <writer> <lotus_std> <lotus_field id="CRMDRightId"/> <convertor> <binary_hexstring/> </convertor> </lotus_std> </writer> </field> <field id="AccountId" ver="1"> <reader> <lotus_std> <lotus_field id="CRMDLeftId"/> <convertor> <binary_hexstring/> </convertor> </lotus_std> </reader> <writer> <lotus_std> <lotus_field id="CRMDLeftId"/> <convertor> <binary_hexstring/> </convertor> </lotus_std> </writer> </field> <field id="LeftStatus" ver="1"> <reader> <lotus_std> <lotus_field id="CRMDLeftStatus"/> <convertor> <string/> </convertor> </lotus_std> </reader> </field> <field id="RightStatus" ver="1"> <reader> <lotus_std> <lotus_field id="CRMDRightStatus"/> <convertor> <string/> </convertor> </lotus_std> </reader> </field> </type>
Specifying the List
The custom object stores items that the user chooses in a list. You describe the list field in the same way as you describe a string field. You must describe the object that stores all list values. Each list uses a separate object to store the values for the list. You must build the IDs for these objects according to the following rules:
- Object name and field
- Name and list
You must make sure the Type list on the Activity object includes the ID of the ActionTypePicklist object. To specify a list object, you must specify the following set of standard fields:
- Label
- Value (string)
- SortOrder (integer)
- IsDefault (Boolean)
In this example, you configuring the Sales Methods drop-down list on the Opportunity form. To specify the list
- Create a new field:
- Open IBM Domino Designer.
For more information, see Opening IBM Domino Designer.
- Create a field of the combobox type.
- Use IBM Domino Designer to specify the filtering parameters for the field you created in Step b.
- Use an XML editor to open the Ln_siebel_basic_mapping.xml file.
- Locate the following code:
<type id="Opportunity" form="sblOpportunity">
- Add the following code immediately following the code you located in Step 3:
<field id="Sales Method" ver="1"> <reader> <lotus_std> <lotus_field id="SalesMethod"/> <convertor> <string/> </convertor> </lotus_std> </reader> <writer> <lotus_std> <lotus_field id="SalesMethod"/> <convertor> <string/> </convertor> </lotus_std> </writer> </field>
- Add the following code anywhere that is not part of code that defines an existing type:
<type id="OpportunitySales MethodPicklist" form="sblConst"> <field id="Label" ver="1"> <reader> <lotus_std> <lotus_field id="Name"/> <convertor> <string/> </convertor> </lotus_std> </reader> <writer> <lotus_std> <lotus_field id="Name"/> <convertor> <string/> </convertor> </lotus_std> </writer> </field> <field id="Value" ver="1"> <reader> <lotus_std> <lotus_field id="Value"/> <convertor> <string/> </convertor> </lotus_std> </reader> <writer> <lotus_std> <lotus_field id="Value"/> <convertor> <string/> </convertor> </lotus_std> </writer> </field> <field id="SortOrder" ver="1"> <reader> <lotus_std> <lotus_field id="SortOrder"/> <convertor> <number/> </convertor> </lotus_std> </reader> <writer> <lotus_std> <lotus_field id="SortOrder"/> <convertor> <number/> </convertor> </lotus_std> </writer> </field> <field id="IsDefault" ver="1"> <reader> <lotus_std> <lotus_field id="IsDefault"/> <convertor> <string_boolean/> </convertor> </lotus_std> </reader> <writer> <lotus_std> <lotus_field id="IsDefault"/> <convertor> <string_boolean/> </convertor> </lotus_std> </writer> </field> </type>
|