Groovy Script Not Triggering On Contact Points

(Doc ID 2246472.1)

Last updated on MARCH 22, 2017

Applies to:

Oracle Fusion Sales - Version to [Release 1.0]
Information in this document applies to any platform.


Making changes to Primary Contact Phone number and want to stamp this value to a custom field.

def countryCode
def areaCode
def phoneNumber

def phoneobj = Phone
def primaryPhoneObject
  def phone =
  // then do something
  def primary = phone.PrimaryFlag
  if(primary == 'Y') {
  primaryPhoneObject = phone ;

if (isAttributeChanged(primaryPhoneObject?.PhoneNumber))
countryCode = primaryPhoneObject.getAttribute('PhoneCountryCode');
areaCode = primaryPhoneObject.getAttribute('PhoneAreaCode');
phoneNumber = primaryPhoneObject.getAttribute('PhoneNumber');
def origPhoneNumber = getOriginalAttributeValue('phoneNumber')
  if(phoneNumber != origPhoneNumber)
def phonePortal = countryCode+areaCode+phoneNumber
println("the portal number:"+phonePortal);


Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms