Quantcast
Channel: CRM Development 論壇
Viewing all articles
Browse latest Browse all 10280

Infinite Loop When Overriding Order Recalculate

$
0
0

Hi There,

I try to override the recalculate behavior of CRM sales orders because I've added custom discount fields in both salesorder and salesorderdetail. This is what I've done already:

  1. Create a pre-processing plugin on create/update of salesorderdetail which recalculates the salesorderdetail fields
  2. Create a pre-processing plugin on update of salesorder which recalculates the salesorder fields. Here I also perform a lookup for related salesorderdetail records to get the required values, but I do not update those salesorderdetail records.

I'm already working on this for a week and cannot find a solution that works.

For some reason I have an infinite loop because the Depth parameter increases until 8 and then it throws an exception. Next to that, CRM seems to overwrite my calculation....

Can someone PLEASE explain to me how I can get this working?


Viewing all articles
Browse latest Browse all 10280

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>