You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by mo...@apache.org on 2008/07/29 16:06:52 UTC

svn commit: r680701 - in /ofbiz/trunk/applications/ecommerce/webapp/ecommerce: cart/microcart.ftl images/checkoutProcess.js

Author: mor
Date: Tue Jul 29 07:06:52 2008
New Revision: 680701

URL: http://svn.apache.org/viewvc?rev=680701&view=rev
Log:
Using <span> intead of <div> does not break the current layout for micro cart. Ajax based updation of micro cart for One Page Checkout - Patch from Brajesh Patel.

Modified:
    ofbiz/trunk/applications/ecommerce/webapp/ecommerce/cart/microcart.ftl
    ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/checkoutProcess.js

Modified: ofbiz/trunk/applications/ecommerce/webapp/ecommerce/cart/microcart.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/ecommerce/webapp/ecommerce/cart/microcart.ftl?rev=680701&r1=680700&r2=680701&view=diff
==============================================================================
--- ofbiz/trunk/applications/ecommerce/webapp/ecommerce/cart/microcart.ftl (original)
+++ ofbiz/trunk/applications/ecommerce/webapp/ecommerce/cart/microcart.ftl Tue Jul 29 07:06:52 2008
@@ -25,9 +25,9 @@
 <div id="microcart">
     <div>
         <#if (shoppingCartSize > 0)>
-            ${uiLabelMap.EcommerceCartHas} ${shoppingCart.getTotalQuantity()}
+            ${uiLabelMap.EcommerceCartHas} <span id="microCartQuantity">${shoppingCart.getTotalQuantity()}</span>
             <#if shoppingCart.getTotalQuantity() == 1>${uiLabelMap.OrderItem}<#else/>${uiLabelMap.OrderItems}</#if>,
-            <@ofbizCurrency amount=shoppingCart.getGrandTotal() isoCode=shoppingCart.getCurrency()/>
+            <span id="microCartTotal"><@ofbizCurrency amount=shoppingCart.getGrandTotal() isoCode=shoppingCart.getCurrency()/></span>
         <#else>
             ${uiLabelMap.OrderShoppingCartEmpty}
         </#if>

Modified: ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/checkoutProcess.js
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/checkoutProcess.js?rev=680701&r1=680700&r2=680701&view=diff
==============================================================================
--- ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/checkoutProcess.js (original)
+++ ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/checkoutProcess.js Tue Jul 29 07:06:52 2008
@@ -477,10 +477,12 @@
                 $('checkoutPanel').hide();
             } else {
                 // Used for edit cart
+                $('microCartQuantity').update(data.totalQuantity);
                 $('cartSubTotal').update(data.subTotalCurrencyFormatted);
                 $('cartDiscountValue').update(data.displayOrderAdjustmentsTotalCurrencyFormatted);
                 $('cartTotalShipping').update(data.totalShippingCurrencyFormatted);
                 $('cartTotalSalesTax').update(data.totalSalesTaxCurrencyFormatted);
+                $('microCartTotal').update(data.displayGrandTotalCurrencyFormatted);
                 $('cartDisplayGrandTotal').update(data.displayGrandTotalCurrencyFormatted);
                 // Used for summary 
                 $('completedCartSubTotal').update(data.subTotalCurrencyFormatted);