Update Field from Opportunity Model with Data in field from Account Model

  • 1
  • Question
  • Updated 3 years ago
  • Answered
Hello, 

I have address fields in the Account Model that I would like to have autopopulated in the Opportunity Model, or at least have a button that will bring them over. 

From my understanding, to create a button I will need add a page title section and add a button that performs multiple actions with an action for each field I want to bring over. If this is correct, I'm not sure what value I should be using for each action. I currently have the first action as: 

Action Type: Update a field on rows
Model: Opportunity
Field: AVSFQB_Billing_Address_C
Value: ??? 

I want to bring over a field from the Account model. 

Thanks for your help 
Photo of David Jordan

David Jordan

  • 148 Points 100 badge 2x thumb

Posted 3 years ago

  • 1
Photo of Anna Wiersema

Anna Wiersema

  • 10,890 Points 10k badge 2x thumb
Hi David!  So for the value you just need to use a template to bring in the field value from the Accounts Model. something like {{$Model.MyAccountModel.data.0.BillingAddress}} where "MyAccountModel" is the name of the Account Model on your page, of course and "BillingAddress" is the name of the field on that model.

Note: this will only bring in the field value from the first row in the Account model.
Photo of Anna Wiersema

Anna Wiersema

  • 10,890 Points 10k badge 2x thumb
Also, you can find more information in this related topic: Question updating field in one model with field from another model.
Photo of David Jordan

David Jordan

  • 148 Points 100 badge 2x thumb
Hi Anna, 

Thanks so much for the quick reply. That did the trick. Where would I find more information on building the templates ( {{$Model.MyAccountModel.data.0.BillingAddress}} )?

Thanks again! 
(Edited)