CDP4S supports relating a Sitecore CDP Guest to a Lead or Contact out of the box. Simply set the Master Lookup Field setting to use the ‘Lead‘FuseIT_CDP4S__Lead__c’ or ‘Contact‘FuseIT_CDP4S__Contact__c’ field on the Sitecore_CDP_Guest__c object.
Info |
---|
The Settings App automatically displays available master objects by name based on the Lookup fields present. |
Other standard or custom objects can also be configured as below.
...
Code Block |
---|
/** * Perform required Personalization and Analytics from associated Opportunity changes. */ trigger CDP4SOpportunityTrigger on Opportunity (before delete, after insert, after update) { if (trigger.isDelete) { // Delete related Guest data if settings allow. FuseIT_CDP4S_.GuestHelper.DeleteGuestsIfCascadeEnabled(Trigger.oldMap.keySet()); } else { // Update Sitecore CDP with mapped data when it changes on an Opportunity. FuseIT_CDP4S_.PersonalizationHelper.UpdatePersonalizationFromTrigger(trigger.new, Trigger.oldMap); } } |