svn commit: r1748570 - /ofbiz/branches/release15.12/applications/order/webapp/ordermgr/order/editorderitems.ftl

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

svn commit: r1748570 - /ofbiz/branches/release15.12/applications/order/webapp/ordermgr/order/editorderitems.ftl

diveshdutta
Author: diveshdutta
Date: Wed Jun 15 12:27:35 2016
New Revision: 1748570

URL: http://svn.apache.org/viewvc?rev=1748570&view=rev
Log:
[OFBIZ-7180] Fixed:Completed Service Order Items are being allowed to be edited over SO and approved PO. Added condition in code so that cancelled and completed order items are not allowed to edit. Thanks Swapnil Shah for reporting the issue and thanks Ratnesh Upadhyay for provinding the fix.

Modified:
    ofbiz/branches/release15.12/applications/order/webapp/ordermgr/order/editorderitems.ftl

Modified: ofbiz/branches/release15.12/applications/order/webapp/ordermgr/order/editorderitems.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release15.12/applications/order/webapp/ordermgr/order/editorderitems.ftl?rev=1748570&r1=1748569&r2=1748570&view=diff
==============================================================================
--- ofbiz/branches/release15.12/applications/order/webapp/ordermgr/order/editorderitems.ftl (original)
+++ ofbiz/branches/release15.12/applications/order/webapp/ordermgr/order/editorderitems.ftl Wed Jun 15 12:27:35 2016
@@ -162,7 +162,7 @@ under the License.
                               </td>
                               <td class="align-text" valign="top" nowrap="nowrap">
                                   <#-- check for permission to modify price -->
-                                  <#if (allowPriceChange)>
+                                  <#if (allowPriceChange) && !(orderItem.statusId == "ITEM_CANCELLED" || orderItem.statusId == "ITEM_COMPLETED")>
                                       <input type="text" size="8" name="ipm_${orderItem.orderItemSeqId}" value="<@ofbizAmount amount=orderItem.unitPrice/>"/>
                                       &nbsp;<input type="checkbox" name="opm_${orderItem.orderItemSeqId}" value="Y"/>
                                   <#else>
@@ -253,12 +253,14 @@ under the License.
                                     <td class="align-text" colspan="2">
                                         <span class="label">${uiLabelMap.OrderShipGroup}</span>&nbsp;[${shipGroup.shipGroupSeqId}] ${shipGroupAddress.address1?default("${uiLabelMap.OrderNotShipped}")}
                                     </td>
-                                    <td align="center">
-                                        <input type="text" name="iqm_${shipGroupAssoc.orderItemSeqId}:${shipGroupAssoc.shipGroupSeqId}" size="6" value="${shipGroupQty?string.number}"/>
-                                        <#if itemSelectable>
-                                            <input type="checkbox" name="selectedItem" value="${orderItem.orderItemSeqId}" />
-                                        </#if>
-                                    </td>
+                                    <#if itemStatusOkay>
+                                        <td align="center">
+                                            <input type="text" name="iqm_${shipGroupAssoc.orderItemSeqId}:${shipGroupAssoc.shipGroupSeqId}" size="6" value="${shipGroupQty?string.number}"/>
+                                            <#if itemSelectable>
+                                                <input type="checkbox" name="selectedItem" value="${orderItem.orderItemSeqId}" />
+                                            </#if>
+                                        </td>
+                                    </#if>
                                     <td colspan="4">&nbsp;</td>
                                     <td>
                                         <#if itemSelectable>