Skip to content
Snippets Groups Projects
Commit 0f77b366 authored by Sebastian Pongratz's avatar Sebastian Pongratz :ping_pong:
Browse files

Merge branch 'sales_1082244_FixDiscountCaluclation' into '2021.1'

[Projekt: xRM-Sales][TicketNr.: 1082244][Fehler in Berechnung des Rabatts in Angebot]

See merge request xrm/basic!1067
parents 2c715936 617dc79e
No related branches found
No related tags found
No related merge requests found
...@@ -643,8 +643,8 @@ OfferItemUtils.getDiscountedNet = function(pExcludedIs, pOfferId, pDiscount, pEx ...@@ -643,8 +643,8 @@ OfferItemUtils.getDiscountedNet = function(pExcludedIs, pOfferId, pDiscount, pEx
if(!offeritemData[i][5].toString().includes(".")//only top items if(!offeritemData[i][5].toString().includes(".")//only top items
&& offeritemData[i][4] == "0")//which are not optional && offeritemData[i][4] == "0")//which are not optional
{ {
sum = eMath.addDec(sum, eMath.subDec(offeritemData[i][1], offeritemData[i][2])*offeritemData[i][0]); sum = eMath.addDec(sum, eMath.subDec(offeritemData[i][1], offeritemData[i][1]/100*offeritemData[i][2])*offeritemData[i][0]);
vat = eMath.addDec(vat, offeritemData[i][3]*eMath.subDec(offeritemData[i][1], offeritemData[i][2])*offeritemData[i][0]/100); vat = eMath.addDec(vat, offeritemData[i][3]*eMath.subDec(offeritemData[i][1], offeritemData[i][1]/100*offeritemData[i][2])*offeritemData[i][0]/100);
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment