Create Object Workflow on the Contact Object

Use this topic to create an object workflow on Contact object.

  1. In Application Composer, expand Common Setup, then select Object Workflows.

  2. Click the Create (+) icon.

  3. Click the Object drop down list, and select Contact.

  4. In the Name field, enter: SyncContactAttributesToIdcsWf.

  5. For Event Point and Condition, select: When a record is updated.

  6. Click in the Condition field, then click the Groovy builder icon.

  7. Copy and paste the following code in the Expression Builder, then click OK.

    if (ContactRole == 'SERVICE' && 
         (isAttributeChanged('PersonFirstName') || isAttributeChanged('PersonLastName')) )
      return true;
    else
      return false;
  8. Click the Create button of the Groovy Script Action.

  9. In the Name field, enter: SyncContactAttributesToIdcsGs.

  10. In the Method Name drop down list, select SyncContactAttributes.

  11. Click Save, and then click Save and Close.