svn commit: r1739467 - /ofbiz/branches/release14.12/applications/order/script/org/ofbiz/order/order/OrderServices.xml

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r1739467 - /ofbiz/branches/release14.12/applications/order/script/org/ofbiz/order/order/OrderServices.xml

Mridul Pathak-5
Author: mridulpathak
Date: Sat Apr 16 14:06:39 2016
New Revision: 1739467

URL: http://svn.apache.org/viewvc?rev=1739467&view=rev
Log:
[OFBIZ-6781] Incorrect order adjustment after order item is cancelled. Thanks Vyom Jain for reporting the issue and Suraj Khurana for providing the patch. Applying fix from trunk r1739463.

Modified:
    ofbiz/branches/release14.12/applications/order/script/org/ofbiz/order/order/OrderServices.xml

Modified: ofbiz/branches/release14.12/applications/order/script/org/ofbiz/order/order/OrderServices.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/release14.12/applications/order/script/org/ofbiz/order/order/OrderServices.xml?rev=1739467&r1=1739466&r2=1739467&view=diff
==============================================================================
--- ofbiz/branches/release14.12/applications/order/script/org/ofbiz/order/order/OrderServices.xml (original)
+++ ofbiz/branches/release14.12/applications/order/script/org/ofbiz/order/order/OrderServices.xml Sat Apr 16 14:06:39 2016
@@ -625,7 +625,10 @@ under the License.
         <iterate list="orderAdjustments" entry="orderAdjustment">
             <if>
                 <condition>
-                    <not><if-empty field="orderAdjustment.productPromoId"/></not>
+                    <and>
+                        <not><if-empty field="orderAdjustment.orderAdjustmentTypeId"/></not>
+                        <if-compare operator="equals" value="PROMOTION_ADJUSTMENT" field="orderAdjustment.orderAdjustmentTypeId"></if-compare>
+                    </and>
                 </condition>
                 <then>
                     <calculate field="existingOrderAdjustmentTotal" decimal-scale="3">
@@ -681,7 +684,10 @@ under the License.
         <iterate list="adjustments" entry="adjustment">
             <if>
                 <condition>
-                    <not><if-empty field="adjustment.productPromoId"/></not>
+                    <and>
+                        <not><if-empty field="adjustment.productPromoId"/></not>
+                        <if-empty field="adjustment.orderAdjustmentId"/>
+                    </and>
                 </condition>
                 <then>
                     <calculate field="newOrderAdjustmentTotal" decimal-scale="3">