function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
TrimbleAgTrimbleAg 

Product Question

We have two types of parts, OEM and Standard. A product can only belong to one or the other, but an Opportunity can contain both, so I had to use one pricebook. I have a field on Accounts called "Discount Level" I want this discount level applied to all product added to a Opp when that account is selected; as the discount level varies by account. But the discount can only pertain to the "Standard" parts. So when a standard part is added to the Opp it pulls the discount automatically.

I can’t seem to figure out a way to do this without a Trigger, is that correct?

 

PB

Best Answer chosen by Admin (Salesforce Developers) 
TrimbleAgTrimbleAg

I created a formula field on the Opp Product Line to grab the discount off of the account by using a cross object formula. Then I created a workflow to update the product line if the product type equaled standard. Then I created a field update for discounts, and used the API Name of the formula field to set the discount field, works like a charm!

 

PB