Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 82002

CalculatePrice Plugin

$
0
0

I have created a plugin which replaces the CalcualtePrice Out-of-the-box pricing engine.

It functions wonderfully, I have set it to retrieve the price list from the parent record and then check against discounts for the quantity.

However there is one last thing which the plugin cant seem to do - update the Line item's volumediscountamount field.

this is a snippet of the code:

lineItemUpdate["volumediscountamount"] = new Money(volumeDiscount);
lineItemUpdate["new_discountedpriceperunit"] = new Money(discountedPPU);
lineItemUpdate["baseamount"] = new Money(baseAmount);
lineItemUpdate["extendedamount"] = new Money(extendedAmount);
service.Update(lineItemUpdate);

All other fields update properly, however the volumediscountamount field stays at zero.

I have checked audit and the field is not being set by the plugin.


Viewing all articles
Browse latest Browse all 82002

Latest Images

Trending Articles



Latest Images