svn commit: r1761497 - in /ofbiz/branches: release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/ release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/ release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/

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

svn commit: r1761497 - in /ofbiz/branches: release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/ release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/ release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/

jleroux@apache.org
Author: jleroux
Date: Mon Sep 19 20:18:28 2016
New Revision: 1761497

URL: http://svn.apache.org/viewvc?rev=1761497&view=rev
Log:
Backports by hand (hard work)
-----------------------------------------------------------------------------------------
Fixes: Bursted Layout in screen "orderstatus" of ecommerce
(OFBIZ-8265)

The layout of screen "order status" of application "ecommerce"  is busted .

I save the html of the screen into my local file, and It works fine. I don't know the reason exactly, but the patch attached by me works correctly.

jleroux: after review I agree it's the right way to fix it. OrderStatus.ftl indirectly calls OrderItems.ftl through the orderitems screen so nothing is lost when the addCommonToCartForm is moved from OrderStatus.ftl to OrderItems.ft, it's only a rearrangement which fixes the issue.

Thanks: fumiyoshi.to
-----------------------------------------------------------------------------------------

Modified:
    ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl
    ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl
    ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl
    ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl
    ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl
    ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl
    ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl
    ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl
    ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl

Modified: ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl (original)
+++ ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl Mon Sep 19 20:18:28 2016
@@ -23,13 +23,9 @@ under the License.
 <#if (orderHeader.externalId)?exists && (orderHeader.externalId)?has_content >
   <#assign externalOrder = "(" + orderHeader.externalId + ")"/>
 </#if>
-
-<div id="orderHeader">
-<#-- left side -->
-<div class="columnLeft">
-<div class="screenlet">
-  <h3>
-    <#if maySelectItems?default("N") == "Y" && returnLink?default("N") == "Y" && (orderHeader.statusId)?if_exists == "ORDER_COMPLETED" && roleTypeId?if_exists == "PLACING_CUSTOMER">
+    <div class="screenlet">
+      <h3>
+      <#if maySelectItems?default("N") == "Y" && returnLink?default("N") == "Y" && (orderHeader.statusId)! == "ORDER_COMPLETED" && roleTypeId! == "PLACING_CUSTOMER">
       <a href="<@ofbizUrl fullPath="true">makeReturn?orderId=${orderHeader.orderId}</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderRequestReturn}</a>
     </#if>
     ${uiLabelMap.OrderOrder}
@@ -226,15 +222,15 @@ under the License.
           </#list>
         </li>
       </#if>
-    </ul>
-  </#if>
-</div>
-</div>
-<#-- right side -->
-<div class="screenlet columnRight">
-  <#if orderItemShipGroups?has_content>
-    <h3>${uiLabelMap.OrderShippingInformation}</h3>
-    <#-- shipping address -->
+        </ul>
+      </#if>
+    </div>
+
+  <#-- right side -->
+  <div class="screenlet">
+    <#if orderItemShipGroups?has_content>
+      <h3>${uiLabelMap.OrderShippingInformation}</h3>
+      <#-- shipping address -->
     <#assign groupIdx = 0>
     <#list orderItemShipGroups as shipGroup>
       <#if orderHeader?has_content>
@@ -358,8 +354,6 @@ under the License.
       </ul>
       <#assign groupIdx = groupIdx + 1>
     </#list><#-- end list of orderItemShipGroups -->
-  </#if>
-</div>
+    </#if>
+  </div>
 
-<div class="clearBoth"></div>
-</div>

Modified: ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl (original)
+++ ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl Mon Sep 19 20:18:28 2016
@@ -21,13 +21,16 @@ under the License.
 <#-- the "urlPrefix" value will be prepended to URLs by the ofbizUrl transform if/when there is no "request" object in the context -->
 <#if baseEcommerceSecureUrl?exists><#assign urlPrefix = baseEcommerceSecureUrl/></#if>
 <div class="screenlet">
+  <form name="addCommonToCartForm" action="<@ofbizUrl>addordertocart/orderstatus</@ofbizUrl>" method="post">
+    <input type="hidden" name="add_all" value="false" />
+    <input type="hidden" name="orderId" value="${orderHeader.orderId}" />
   <h3>
-      <#assign numColumns = 8>
-      <#if maySelectItems?default("N") == "Y" && roleTypeId?if_exists == "PLACING_CUSTOMER">
-          <#assign numColumns = 11>
+    <#assign numColumns = 8>
+    ${uiLabelMap.OrderOrderItems}
+    <#if maySelectItems?default("N") == "Y" && roleTypeId! == "PLACING_CUSTOMER">
+      <#assign numColumns = 11>
           <a href="javascript:document.addCommonToCartForm.add_all.value='true';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddAllToCart}</a><a href="javascript:document.addCommonToCartForm.add_all.value='false';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddCheckedToCart}</a><a href="<@ofbizUrl fullPath="true">createShoppingListFromOrder?orderId=${orderHeader.orderId}&amp;frequency=6&amp;intervalNumber=1&amp;shoppingListTypeId=SLT_AUTO_REODR</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderSendMeThisEveryMonth}</a>
       </#if>
-      ${uiLabelMap.OrderOrderItems}
   </h3>
   <table>
     <thead>
@@ -298,4 +301,5 @@ under the License.
     <tr><td colspan="${numColumns}"></td></tr>
     </tbody>
   </table>
+  </form>
 </div>

Modified: ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl (original)
+++ ofbiz/branches/release13.07/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl Mon Sep 19 20:18:28 2016
@@ -17,14 +17,9 @@ specific language governing permissions
 under the License.
 -->
 <#if orderHeader?has_content>
-  <form name="addCommonToCartForm" action="<@ofbizUrl>addordertocart/orderstatus</@ofbizUrl>" method="post">
-    <input type="hidden" name="add_all" value="false" />
-    <input type="hidden" name="orderId" value="${orderHeader.orderId}" />
     ${screens.render("component://ecommerce/widget/OrderScreens.xml#orderheader")}
     <br />
     ${screens.render("component://ecommerce/widget/OrderScreens.xml#orderitems")}
-  </form>
-
 <#else>
   <h3>${uiLabelMap.OrderSpecifiedNotFound}.</h3>
 </#if>

Modified: ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl (original)
+++ ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl Mon Sep 19 20:18:28 2016
@@ -24,12 +24,9 @@ under the License.
   <#assign externalOrder = "(" + orderHeader.externalId + ")"/>
 </#if>
 
-<div id="orderHeader">
-<#-- left side -->
-<div class="columnLeft">
-<div class="screenlet">
-  <h3>
-    <#if maySelectItems?default("N") == "Y" && returnLink?default("N") == "Y" && (orderHeader.statusId)! == "ORDER_COMPLETED" && roleTypeId! == "PLACING_CUSTOMER">
+    <div class="screenlet">
+      <h3>
+      <#if maySelectItems?default("N") == "Y" && returnLink?default("N") == "Y" && (orderHeader.statusId)! == "ORDER_COMPLETED" && roleTypeId! == "PLACING_CUSTOMER">
       <a href="<@ofbizUrl fullPath="true">makeReturn?orderId=${orderHeader.orderId}</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderRequestReturn}</a>
     </#if>
     ${uiLabelMap.OrderOrder}
@@ -226,15 +223,15 @@ under the License.
           </#list>
         </li>
       </#if>
-    </ul>
-  </#if>
-</div>
-</div>
-<#-- right side -->
-<div class="screenlet columnRight">
-  <#if orderItemShipGroups?has_content>
-    <h3>${uiLabelMap.OrderShippingInformation}</h3>
-    <#-- shipping address -->
+        </ul>
+      </#if>
+    </div>
+
+  <#-- right side -->
+  <div class="screenlet">
+    <#if orderItemShipGroups?has_content>
+      <h3>${uiLabelMap.OrderShippingInformation}</h3>
+      <#-- shipping address -->
     <#assign groupIdx = 0>
     <#list orderItemShipGroups as shipGroup>
       <#if orderHeader?has_content>
@@ -358,8 +355,6 @@ under the License.
       </ul>
       <#assign groupIdx = groupIdx + 1>
     </#list><#-- end list of orderItemShipGroups -->
-  </#if>
-</div>
+    </#if>
+  </div>
 
-<div class="clearBoth"></div>
-</div>

Modified: ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl (original)
+++ ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl Mon Sep 19 20:18:28 2016
@@ -21,13 +21,16 @@ under the License.
 <#-- the "urlPrefix" value will be prepended to URLs by the ofbizUrl transform if/when there is no "request" object in the context -->
 <#if baseEcommerceSecureUrl??><#assign urlPrefix = baseEcommerceSecureUrl/></#if>
 <div class="screenlet">
+  <form name="addCommonToCartForm" action="<@ofbizUrl>addordertocart/orderstatus</@ofbizUrl>" method="post">
+    <input type="hidden" name="add_all" value="false" />
+    <input type="hidden" name="orderId" value="${orderHeader.orderId}" />
   <h3>
-      <#assign numColumns = 8>
-      <#if maySelectItems?default("N") == "Y" && roleTypeId! == "PLACING_CUSTOMER">
-          <#assign numColumns = 11>
+    <#assign numColumns = 8>
+    ${uiLabelMap.OrderOrderItems}
+    <#if maySelectItems?default("N") == "Y" && roleTypeId! == "PLACING_CUSTOMER">
+      <#assign numColumns = 11>
           <a href="javascript:document.addCommonToCartForm.add_all.value='true';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddAllToCart}</a><a href="javascript:document.addCommonToCartForm.add_all.value='false';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddCheckedToCart}</a><a href="<@ofbizUrl fullPath="true">createShoppingListFromOrder?orderId=${orderHeader.orderId}&amp;frequency=6&amp;intervalNumber=1&amp;shoppingListTypeId=SLT_AUTO_REODR</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderSendMeThisEveryMonth}</a>
       </#if>
-      ${uiLabelMap.OrderOrderItems}
   </h3>
   <table>
     <thead>
@@ -298,4 +301,5 @@ under the License.
     <tr><td colspan="${numColumns}"></td></tr>
     </tbody>
   </table>
+  </form>
 </div>

Modified: ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl (original)
+++ ofbiz/branches/release14.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl Mon Sep 19 20:18:28 2016
@@ -17,14 +17,9 @@ specific language governing permissions
 under the License.
 -->
 <#if orderHeader?has_content>
-  <form name="addCommonToCartForm" action="<@ofbizUrl>addordertocart/orderstatus</@ofbizUrl>" method="post">
-    <input type="hidden" name="add_all" value="false" />
-    <input type="hidden" name="orderId" value="${orderHeader.orderId}" />
     ${screens.render("component://ecommerce/widget/OrderScreens.xml#orderheader")}
     <br />
     ${screens.render("component://ecommerce/widget/OrderScreens.xml#orderitems")}
-  </form>
-
 <#else>
   <h3>${uiLabelMap.OrderSpecifiedNotFound}.</h3>
 </#if>

Modified: ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl (original)
+++ ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderheader.ftl Mon Sep 19 20:18:28 2016
@@ -24,12 +24,9 @@ under the License.
   <#assign externalOrder = "(" + orderHeader.externalId + ")"/>
 </#if>
 
-<div id="orderHeader">
-<#-- left side -->
-<div class="columnLeft">
-<div class="screenlet">
-  <h3>
-    <#if maySelectItems?default("N") == "Y" && returnLink?default("N") == "Y" && (orderHeader.statusId)! == "ORDER_COMPLETED" && roleTypeId! == "PLACING_CUSTOMER">
+    <div class="screenlet">
+      <h3>
+      <#if maySelectItems?default("N") == "Y" && returnLink?default("N") == "Y" && (orderHeader.statusId)! == "ORDER_COMPLETED" && roleTypeId! == "PLACING_CUSTOMER">
       <a href="<@ofbizUrl fullPath="true">makeReturn?orderId=${orderHeader.orderId}</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderRequestReturn}</a>
     </#if>
     ${uiLabelMap.OrderOrder}
@@ -226,15 +223,15 @@ under the License.
           </#list>
         </li>
       </#if>
-    </ul>
-  </#if>
-</div>
-</div>
-<#-- right side -->
-<div class="screenlet columnRight">
-  <#if orderItemShipGroups?has_content>
-    <h3>${uiLabelMap.OrderShippingInformation}</h3>
-    <#-- shipping address -->
+        </ul>
+      </#if>
+    </div>
+
+  <#-- right side -->
+  <div class="screenlet">
+    <#if orderItemShipGroups?has_content>
+      <h3>${uiLabelMap.OrderShippingInformation}</h3>
+      <#-- shipping address -->
     <#assign groupIdx = 0>
     <#list orderItemShipGroups as shipGroup>
       <#if orderHeader?has_content>
@@ -358,8 +355,6 @@ under the License.
       </ul>
       <#assign groupIdx = groupIdx + 1>
     </#list><#-- end list of orderItemShipGroups -->
-  </#if>
-</div>
+    </#if>
+  </div>
 
-<div class="clearBoth"></div>
-</div>

Modified: ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl (original)
+++ ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderitems.ftl Mon Sep 19 20:18:28 2016
@@ -21,13 +21,16 @@ under the License.
 <#-- the "urlPrefix" value will be prepended to URLs by the ofbizUrl transform if/when there is no "request" object in the context -->
 <#if baseEcommerceSecureUrl??><#assign urlPrefix = baseEcommerceSecureUrl/></#if>
 <div class="screenlet">
+  <form name="addCommonToCartForm" action="<@ofbizUrl>addordertocart/orderstatus</@ofbizUrl>" method="post">
+    <input type="hidden" name="add_all" value="false" />
+    <input type="hidden" name="orderId" value="${orderHeader.orderId}" />
   <h3>
-      <#assign numColumns = 8>
-      <#if maySelectItems?default("N") == "Y" && roleTypeId! == "PLACING_CUSTOMER">
-          <#assign numColumns = 11>
+    <#assign numColumns = 8>
+    ${uiLabelMap.OrderOrderItems}
+    <#if maySelectItems?default("N") == "Y" && roleTypeId! == "PLACING_CUSTOMER">
+      <#assign numColumns = 11>
           <a href="javascript:document.addCommonToCartForm.add_all.value='true';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddAllToCart}</a><a href="javascript:document.addCommonToCartForm.add_all.value='false';document.addCommonToCartForm.submit()" class="submenutext">${uiLabelMap.OrderAddCheckedToCart}</a><a href="<@ofbizUrl fullPath="true">createShoppingListFromOrder?orderId=${orderHeader.orderId}&amp;frequency=6&amp;intervalNumber=1&amp;shoppingListTypeId=SLT_AUTO_REODR</@ofbizUrl>" class="submenutextright">${uiLabelMap.OrderSendMeThisEveryMonth}</a>
       </#if>
-      ${uiLabelMap.OrderOrderItems}
   </h3>
   <table>
     <thead>
@@ -298,4 +301,5 @@ under the License.
     <tr><td colspan="${numColumns}"></td></tr>
     </tbody>
   </table>
+  </form>
 </div>

Modified: ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl
URL: http://svn.apache.org/viewvc/ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl?rev=1761497&r1=1761496&r2=1761497&view=diff
==============================================================================
--- ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl (original)
+++ ofbiz/branches/release15.12/specialpurpose/ecommerce/webapp/ecommerce/order/orderstatus.ftl Mon Sep 19 20:18:28 2016
@@ -17,14 +17,9 @@ specific language governing permissions
 under the License.
 -->
 <#if orderHeader?has_content>
-  <form name="addCommonToCartForm" action="<@ofbizUrl>addordertocart/orderstatus</@ofbizUrl>" method="post">
-    <input type="hidden" name="add_all" value="false" />
-    <input type="hidden" name="orderId" value="${orderHeader.orderId}" />
     ${screens.render("component://ecommerce/widget/OrderScreens.xml#orderheader")}
     <br />
     ${screens.render("component://ecommerce/widget/OrderScreens.xml#orderitems")}
-  </form>
-
 <#else>
   <h3>${uiLabelMap.OrderSpecifiedNotFound}.</h3>
 </#if>