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/10/23 13:36:31 UTC

svn commit: r707349 - in /ofbiz/trunk/applications: ecommerce/script/org/ofbiz/ecommerce/customer/ ecommerce/webapp/ecommerce/images/ ecommerce/webapp/ecommerce/order/ order/servicedef/

Author: mor
Date: Thu Oct 23 04:36:30 2008
New Revision: 707349

URL: http://svn.apache.org/viewvc?rev=707349&view=rev
Log:
Fix:Few countries does not have any state. Made the state field on One Page Checkout as an optional field. 
Applied patch from Jira Issue OFBIZ-2014 (https://issues.apache.org/jira/browse/OFBIZ-2014)
Thanks to Onima Kasliwal and Rishi Solanki.

Modified:
    ofbiz/trunk/applications/ecommerce/script/org/ofbiz/ecommerce/customer/CheckoutMapProcs.xml
    ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/geoAutoCompleter.js
    ofbiz/trunk/applications/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl
    ofbiz/trunk/applications/order/servicedef/services.xml

Modified: ofbiz/trunk/applications/ecommerce/script/org/ofbiz/ecommerce/customer/CheckoutMapProcs.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/ecommerce/script/org/ofbiz/ecommerce/customer/CheckoutMapProcs.xml?rev=707349&r1=707348&r2=707349&view=diff
==============================================================================
--- ofbiz/trunk/applications/ecommerce/script/org/ofbiz/ecommerce/customer/CheckoutMapProcs.xml (original)
+++ ofbiz/trunk/applications/ecommerce/script/org/ofbiz/ecommerce/customer/CheckoutMapProcs.xml Thu Oct 23 04:36:30 2008
@@ -105,9 +105,6 @@
         </process>
         <process field="shipToStateProvinceGeoId">
             <copy to-field="stateProvinceGeoId"/>
-            <not-empty>
-                <fail-property resource="EcommerceUiLabels" property="PartyStateMissingError"/>
-            </not-empty>
         </process>
         <process field="shipToPostalCode">
             <copy to-field="postalCode"/>
@@ -150,9 +147,6 @@
         </process>
         <process field="billToStateProvinceGeoId">
             <copy to-field="stateProvinceGeoId"/>
-            <not-empty>
-                <fail-property resource="EcommerceUiLabels" property="PartyStateMissingError"/>
-            </not-empty>
         </process>
         <process field="billToPostalCode">
             <copy to-field="postalCode"/>

Modified: ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/geoAutoCompleter.js
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/geoAutoCompleter.js?rev=707349&r1=707348&r2=707349&view=diff
==============================================================================
--- ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/geoAutoCompleter.js (original)
+++ ofbiz/trunk/applications/ecommerce/webapp/ecommerce/images/geoAutoCompleter.js Thu Oct 23 04:36:30 2008
@@ -22,6 +22,7 @@
     getCountryList();
     Event.observe('shipToCountryGeo', 'change', function() {
         $('shipToStateProvinceGeo').value = "";
+        $('shipToStateProvinceGeoId').value = "";
     });
 });
 

Modified: ofbiz/trunk/applications/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl?rev=707349&r1=707348&r2=707349&view=diff
==============================================================================
--- ofbiz/trunk/applications/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl (original)
+++ ofbiz/trunk/applications/ecommerce/webapp/ecommerce/order/OnePageCheckoutProcess.ftl Thu Oct 23 04:36:30 2008
@@ -355,11 +355,11 @@
                     </div>
                     <div class="form-row">
                       <div class="field-label">
-                        <label for="state">${uiLabelMap.CommonState}*<span id="advice-required-shipToStateProvinceGeo" style="display:none" class="errorMessage"> (required)</span></label>
+                        <label for="state">${uiLabelMap.CommonState}</label>
                       </div>
                       <div> 
                         <div>
-                          <input name="shipToStateProvinceGeo" id="shipToStateProvinceGeo" size="30" class="required" type="text" value="${shipToStateProvinceGeo?if_exists}"/>
+                          <input name="shipToStateProvinceGeo" id="shipToStateProvinceGeo" size="30" type="text" value="${shipToStateProvinceGeo?if_exists}"/>
                           <input name="shipToStateProvinceGeoId" id="shipToStateProvinceGeoId" type="hidden" value="${shipToStateProvinceGeoId?if_exists}"/>
                           <div id="shipToStates" class="autocomplete" style="display:none"></div> 
                         </div>
@@ -629,10 +629,10 @@
                       </div>
                       <div class="form-row">
                         <div class="field-label">
-                           <label for="state">${uiLabelMap.CommonState}*<span id="advice-required-billToStateProvinceGeoId" style="display:none" class="errorMessage"> (required)</span></label>
+                           <label for="state">${uiLabelMap.CommonState}</label>
                         </div>
                         <div> 
-                          <select id="billToStateProvinceGeoId" name="billToStateProvinceGeoId" class="required selectBox">
+                          <select id="billToStateProvinceGeoId" name="billToStateProvinceGeoId" class="selectBox">
                             <#if billToStateProvinceGeoId?has_content>
                               <option value="${billToStateProvinceGeoId}">${billToStateProvinceGeo}</option>
                             <#else>

Modified: ofbiz/trunk/applications/order/servicedef/services.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/servicedef/services.xml?rev=707349&r1=707348&r2=707349&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/servicedef/services.xml (original)
+++ ofbiz/trunk/applications/order/servicedef/services.xml Thu Oct 23 04:36:30 2008
@@ -857,7 +857,7 @@
         <attribute name="shipToAddress1" mode="IN" type="String" optional="false"/>
         <attribute name="shipToAddress2" mode="IN" type="String" optional="true"/>
         <attribute name="shipToCity" mode="IN" type="String" optional="false"/>
-        <attribute name="shipToStateProvinceGeoId" mode="IN" type="String" optional="false"/>
+        <attribute name="shipToStateProvinceGeoId" mode="IN" type="String" optional="true"/>
         <attribute name="shipToPostalCode" mode="IN" type="String" optional="false"/>
         <attribute name="shipToCountryGeoId" mode="IN" type="String" optional="false"/>
         <attribute name="shipToContactMechId" mode="IN" type="String" optional="true"/>
@@ -879,7 +879,7 @@
         <attribute name="billToAddress1" mode="IN" type="String" optional="false"/>
         <attribute name="billToAddress2" mode="IN" type="String" optional="true"/>
         <attribute name="billToCity" mode="IN" type="String" optional="false"/>
-        <attribute name="billToStateProvinceGeoId" mode="IN" type="String" optional="false"/>
+        <attribute name="billToStateProvinceGeoId" mode="IN" type="String" optional="true"/>
         <attribute name="billToPostalCode" mode="IN" type="String" optional="false"/>
         <attribute name="billToCountryGeoId" mode="IN" type="String" optional="false"/>
         <attribute name="shipToContactMechId" mode="IN" type="String" optional="true"/>