How do I set the parent of an account using Groovy in Oracle Sales in the Redwood User Experience?
Here's sample Groovy to set the parent of an account.
- Object : Account
- Trigger : Before Update
if(ParentAccount_Id_c != null)
{
def newParent = ParentParty
def row = newParent.createRow()
row.setAttribute('PartyId',ParentAccount_Id_c)
newParent.insertRow(row)
}