Author: nmalin
Date: Sat Jan 6 14:58:14 2018
New Revision: 1820403
URL: http://svn.apache.org/viewvc?rev=1820403&view=rev
Log:
Fixed: Display the included vat amount on order item detail instead of 0
(OFBIZ-10148)
When you use a product price with included vat tax, the orderAdjustment created
have an amount to 0 but amount already included with the vat.
When we display the order adjustment detail for an order item we use only
amount (so 0).
Now if the orderAdjustment have an amountAlreadyIncluded not empty, we display
it instead.
Modified:
ofbiz/ofbiz-framework/trunk/applications/order/template/entry/order/OrderItems.ftl
ofbiz/ofbiz-framework/trunk/applications/order/template/order/EditOrderItems.ftl
ofbiz/ofbiz-framework/trunk/applications/order/template/order/OrderItems.ftl
Modified:
ofbiz/ofbiz-framework/trunk/applications/order/template/entry/order/OrderItems.ftl
URL:
http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/applications/order/template/entry/order/OrderItems.ftl?rev=1820403&r1=1820402&r2=1820403&view=diff
==============================================================================
---
ofbiz/ofbiz-framework/trunk/applications/order/template/entry/order/OrderItems.ftl
(original)
+++
ofbiz/ofbiz-framework/trunk/applications/order/template/entry/order/OrderItems.ftl
Sat Jan 6 14:58:14 2018
@@ -115,7 +115,13 @@ under the License.
<td> </td>
<td> </td>
<td align="right">
- <div style="font-size: xx-small;"><@ofbizCurrency
amount=localOrderReadHelper.getOrderItemAdjustmentTotal(orderItem,
orderItemAdjustment) isoCode=currencyUomId/></div>
+ <div style="font-size: xx-small;">
+ <#if orderItemAdjustment.amountAlreadyIncluded?has_content>
+ <@ofbizCurrency
amount=orderItemAdjustment.amountAlreadyIncluded isoCode=currencyUomId/>
+ <#else>
+ <@ofbizCurrency
amount=localOrderReadHelper.getOrderItemAdjustmentTotal(orderItem,
orderItemAdjustment) isoCode=currencyUomId/>
+ </#if>
+ </div>
</td>
<td> </td>
<td> </td>
Modified:
ofbiz/ofbiz-framework/trunk/applications/order/template/order/EditOrderItems.ftl
URL:
http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/applications/order/template/order/EditOrderItems.ftl?rev=1820403&r1=1820402&r2=1820403&view=diff
==============================================================================
---
ofbiz/ofbiz-framework/trunk/applications/order/template/order/EditOrderItems.ftl
(original)
+++
ofbiz/ofbiz-framework/trunk/applications/order/template/order/EditOrderItems.ftl
Sat Jan 6 14:58:14 2018
@@ -230,7 +230,11 @@ under the License.
<td> </td>
<td> </td>
<td class="align-text">
- <@ofbizCurrency
amount=Static["org.apache.ofbiz.order.order.OrderReadHelper"].calcItemAdjustment(orderItemAdjustment,
orderItem) isoCode=currencyUomId/>
+ <#if
orderItemAdjustment.amountAlreadyIncluded?has_content>
+ <@ofbizCurrency
amount=orderItemAdjustment.amountAlreadyIncluded isoCode=currencyUomId/>
+ <#else>
+ <@ofbizCurrency
amount=Static["org.apache.ofbiz.order.order.OrderReadHelper"].calcItemAdjustment(orderItemAdjustment,
orderItem) isoCode=currencyUomId/>
+ </#if>
</td>
<td colspan="3"> </td>
</tr>
Modified:
ofbiz/ofbiz-framework/trunk/applications/order/template/order/OrderItems.ftl
URL:
http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/applications/order/template/order/OrderItems.ftl?rev=1820403&r1=1820402&r2=1820403&view=diff
==============================================================================
---
ofbiz/ofbiz-framework/trunk/applications/order/template/order/OrderItems.ftl
(original)
+++
ofbiz/ofbiz-framework/trunk/applications/order/template/order/OrderItems.ftl
Sat Jan 6 14:58:14 2018
@@ -455,7 +455,11 @@ under the License.
<td> </td>
<td> </td>
<td align="right">
- <@ofbizCurrency
amount=Static["org.apache.ofbiz.order.order.OrderReadHelper"].calcItemAdjustment(orderItemAdjustment,
orderItem) isoCode=currencyUomId/>
+ <#if
orderItemAdjustment.amountAlreadyIncluded?has_content>
+ <@ofbizCurrency
amount=orderItemAdjustment.amountAlreadyIncluded isoCode=currencyUomId/>
+ <#else>
+ <@ofbizCurrency
amount=Static["org.apache.ofbiz.order.order.OrderReadHelper"].calcItemAdjustment(orderItemAdjustment,
orderItem) isoCode=currencyUomId/>
+ </#if>
</td>
<td colspan="2"> </td>
</tr>