Hi,
I have a service to create a sales order, where i pass the Qty,SalesPrice and LineAmount.
I want to say that if Qty*SalesPrice sent to the service really equal the lineAmount sent then keep it. However, if it's wrong then i want recalculate SalesPrice based on the sent LineAmount
My question is, which is the correct method to use, salesLine.calcLineAmount() or salesLine.calcLineAmountForced() or salesLine.calcLineAmountForcedInteraction()? what's the difference?
salesLine.SalesQty = _reqLine.Qty(); //assume reqLine is defined
salesLine.SalesPrice = _reqLine.Price();
real x= salesLine.calcLineAmount();
real y = salesLine.calcLineAmountForced();
real z = salesLine.salesLine.calcLineAmountForcedInteraction(); //this one need a parameter to be passed
if(x != _reqLine.LineAmount())
{
salesLine.SalesPrice = _reqLine.LineAmount()/salesLine.Qty;
}
salesLine.LineAmount = _reqLine.LineAmount();


Report
All responses (
Answers (