Re: svn commit: r432836 - in /incubator/ofbiz/trunk/applications/order: src/org/ofbiz/order/shoppingcart/ webapp/ordermgr/WEB-INF/actions/entry/ webapp/ordermgr/entry/ widget/ordermgr/

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

Re: svn commit: r432836 - in /incubator/ofbiz/trunk/applications/order: src/org/ofbiz/order/shoppingcart/ webapp/ordermgr/WEB-INF/actions/entry/ webapp/ordermgr/entry/ widget/ordermgr/

BJ Freeman
jacopoc:
 <#if carrierShipmentMethod.partyId !=
"_NA_">${carrierShipmentMethod.partyId?if_exists}&nbsp;</#if>

the _NA_ was ment to satify db views.
using this as an ID is confusing.
also there was discussion about the rendering files not showing _NA_ ID
of records that carried it, just the record,
at one time.

 ========================
BJ Freeman
http://bjfreeman.elance.com
Strategic Power Office with Supplier Automation <http://www.businessesnetwork.com/automation/viewforum.php?f=93>
Specialtymarket.com <http://www.specialtymarket.com/>

Systems Integrator-- Glad to Assist

Chat  Y! messenger: bjfr33man
Linkedin
<http://www.linkedin.com/profile?viewProfile=&key=1237480&locale=en_US&trk=tab_pro>


[hidden email] sent the following on 8/19/2006 6:55 AM:

> Author: jacopoc
> Date: Sat Aug 19 06:55:15 2006
> New Revision: 432836
>
> URL: http://svn.apache.org/viewvc?rev=432836&view=rev
> Log:
> First pass in the implementation of the user interface to create, in the order entry checkout process, more than one ship group.
> It is now possible to create ship groups and set different addresses and options for them but it is still not possible to assign the products in the cart to them.
> I'm going to start the implementation of a new checkout screen that will allow this.
>
> Added:
>     incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl   (with props)
> Modified:
>     incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java
>     incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java
>     incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java
>     incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/optionsettings.bsh
>     incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/shipsettings.bsh
>     incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/billsettings.ftl
>     incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/optionsettings.ftl
>     incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipsettings.ftl
>     incubator/ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml
>
> Modified: incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java (original)
> +++ incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java Sat Aug 19 06:55:15 2006
> @@ -627,6 +627,7 @@
>  
>          Map paramMap = UtilHttp.getParameterMap(request);
>          Boolean offlinePayments;
> +        String shipGroupIndexPar = null;
>          String shippingContactMechId = null;
>          String shippingMethod = null;
>          String shippingInstructions = null;
> @@ -709,6 +710,16 @@
>              isAnonymousCheckout = true;
>          }
>  
> +        shipGroupIndexPar = request.getParameter("shipGroupIndex");
> +        int shipGroupIndex = 0;
> +        if (shipGroupIndexPar != null) {
> +            try {
> +                shipGroupIndex = Integer.parseInt(shipGroupIndexPar);
> +            } catch(Exception exc) {
> +                Debug.logWarning("Unable to parse shipGroupIndex [" + shipGroupIndexPar + "]: " + exc.getMessage(), module);
> +            }
> +        }
> +
>          // get the shipping method
>          shippingContactMechId = request.getParameter("shipping_contact_mech_id");
>          if (shippingContactMechId == null) {
> @@ -777,7 +788,7 @@
>              checkOutHelper.setCheckOutPayment(selectedPaymentMethods, null, billingAccountId, billingAccountAmt);
>          }
>  
> -        Map callResult = checkOutHelper.finalizeOrderEntry(mode, shippingContactMechId, shippingMethod, shippingInstructions,
> +        Map callResult = checkOutHelper.finalizeOrderEntry(mode, shipGroupIndex, shippingContactMechId, shippingMethod, shippingInstructions,
>                  maySplit, giftMessage, isGift, methodType, checkOutPaymentId, isSingleUsePayment, doAppendPayment, paramMap,
>                  internalCode, shipBeforeDate, shipAfterDate);
>  
> @@ -818,9 +829,9 @@
>              requireAdditionalParty = requireAdditionalPartyStr == null || requireAdditionalPartyStr.equalsIgnoreCase("true");
>          }
>  
> -        String shipContactMechId = cart.getShippingContactMechId();
>          String customerPartyId = cart.getPartyId();
> -        String shipmentMethodTypeId = cart.getShipmentMethodTypeId();
> +        String shipContactMechId = cart.getShippingContactMechId(shipGroupIndex);
> +        String shipmentMethodTypeId = cart.getShipmentMethodTypeId(shipGroupIndex);
>          List paymentMethodIds = cart.getPaymentMethodIds();
>          List paymentMethodTypeIds = cart.getPaymentMethodTypeIds();
>  
>
> Modified: incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java (original)
> +++ incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java Sat Aug 19 06:55:15 2006
> @@ -1231,18 +1231,19 @@
>      }
>  
>      /**
> -     * Sets the shipping contact mechanism on the cart
> +     * Sets the shipping contact mechanism for a given ship group on the cart
>       *
> +     * @param shipGroupIndex The index of the ship group in the cart
>       * @param shippingContactMechId The identifier of the contact
>       * @return A Map conforming to the OFBiz Service conventions containing
>       * any error messages
>       */
> -    public Map finalizeOrderEntryShip(String shippingContactMechId) {
> +    public Map finalizeOrderEntryShip(int shipGroupIndex, String shippingContactMechId) {
>          Map result;
>          String errMsg=null;
>          //Verify the field is valid
>          if (UtilValidate.isNotEmpty(shippingContactMechId)) {
> -            this.cart.setShippingContactMechId(shippingContactMechId);
> +            this.cart.setShippingContactMechId(shipGroupIndex, shippingContactMechId);
>              result = ServiceUtil.returnSuccess();
>          } else {
>              errMsg = UtilProperties.getMessage(resource,"checkhelper.enter_shipping_address", (cart != null ? cart.getLocale() : Locale.getDefault()));
> @@ -1253,8 +1254,9 @@
>      }
>  
>      /**
> -     * Sets the options associated with the order
> +     * Sets the options associated with the order for a given ship group
>       *
> +     * @param shipGroupIndex The index of the ship group in the cart
>       * @param shippingMethod The shipping method indicating the carrier and
>       * shipment type to use
>       * @param shippingInstructions Any additional handling instructions
> @@ -1265,7 +1267,7 @@
>       * @return A Map conforming to the OFBiz Service conventions containing
>       * any error messages
>       */
> -    public Map finalizeOrderEntryOptions(String shippingMethod, String shippingInstructions, String maySplit,
> +    public Map finalizeOrderEntryOptions(int shipGroupIndex, String shippingMethod, String shippingInstructions, String maySplit,
>              String giftMessage, String isGift, String internalCode, String shipBeforeDate, String shipAfterDate) {
>  
>          Map result;
> @@ -1281,19 +1283,19 @@
>                  carrierPartyId = shippingMethod.substring(delimiterPos + 1);
>              }
>  
> -            this.cart.setShipmentMethodTypeId(shipmentMethodTypeId);
> -            this.cart.setCarrierPartyId(carrierPartyId);
> +            this.cart.setShipmentMethodTypeId(shipGroupIndex, shipmentMethodTypeId);
> +            this.cart.setCarrierPartyId(shipGroupIndex, carrierPartyId);
>          } else {
>              errMsg = UtilProperties.getMessage(resource,"checkhelper.select_shipping_method", (cart != null ? cart.getLocale() : Locale.getDefault()));
>              result = ServiceUtil.returnError(errMsg);
>          }
>  
>          //Set the remaining order options
> -        this.cart.setShippingInstructions(shippingInstructions);
> -        this.cart.setGiftMessage(giftMessage);
> -        this.cart.setMaySplit(Boolean.valueOf(maySplit));
> -        this.cart.setIsGift(Boolean.valueOf(isGift));
> -        this.cart.setInternalCode(internalCode);
> +        this.cart.setShippingInstructions(shipGroupIndex, shippingInstructions);
> +        this.cart.setGiftMessage(shipGroupIndex, giftMessage);
> +        this.cart.setMaySplit(shipGroupIndex, Boolean.valueOf(maySplit));
> +        this.cart.setIsGift(shipGroupIndex, Boolean.valueOf(isGift));
> +        this.cart.setInternalCode(internalCode); // FIXME: the internalCode is not a ship group field and should be moved outside of this method
>  
>          // set ship before date
>          if ((shipBeforeDate != null) && (shipBeforeDate.length() > 8)) {
> @@ -1303,7 +1305,7 @@
>             }
>  
>             try {
> -               this.cart.setShipBeforeDate((Timestamp) ObjectType.simpleTypeConvert(shipBeforeDate, "Timestamp", null, null));
> +               this.cart.setShipBeforeDate(shipGroupIndex, (Timestamp) ObjectType.simpleTypeConvert(shipBeforeDate, "Timestamp", null, null));
>             } catch (Exception e) {
>                 errMsg = "Ship Before Date must be a valid date formed ";
>                 result = ServiceUtil.returnError(errMsg);
> @@ -1318,7 +1320,7 @@
>             }
>  
>             try {
> -               this.cart.setShipAfterDate((Timestamp) ObjectType.simpleTypeConvert(shipAfterDate,"Timestamp", null, null));
> +               this.cart.setShipAfterDate(shipGroupIndex, (Timestamp) ObjectType.simpleTypeConvert(shipAfterDate,"Timestamp", null, null));
>              } catch (Exception e) {
>                errMsg = "Ship After Date must be a valid date formed ";
>                result = ServiceUtil.returnError(errMsg);
> @@ -1362,7 +1364,7 @@
>       * @see CheckOutHelper#finalizeOrderEntryPayment(String, Double, boolean, boolean)
>       * @see CheckOutHelper#finalizeOrderEntryShip(String)
>       */
> -    public Map finalizeOrderEntry(String finalizeMode, String shippingContactMechId, String shippingMethod,
> +    public Map finalizeOrderEntry(String finalizeMode, int shipGroupIndex, String shippingContactMechId, String shippingMethod,
>              String shippingInstructions, String maySplit, String giftMessage, String isGift, String methodType,
>              String checkOutPaymentId, boolean isSingleUsePayment, boolean appendPayment, Map params,
>              String internalCode, String shipBeforeDate, String shipAfterDate) {
> @@ -1374,13 +1376,13 @@
>  
>          // set the shipping method
>          if (finalizeMode != null && finalizeMode.equals("ship")) {
> -            callResult = this.finalizeOrderEntryShip(shippingContactMechId);
> +            callResult = this.finalizeOrderEntryShip(shipGroupIndex, shippingContactMechId);
>              this.addErrors(errorMessages, errorMaps, callResult);
>          }
>  
>          // set the options
>          if (finalizeMode != null && finalizeMode.equals("options")) {
> -            callResult = this.finalizeOrderEntryOptions(shippingMethod, shippingInstructions, maySplit, giftMessage, isGift, internalCode, shipBeforeDate, shipAfterDate);
> +            callResult = this.finalizeOrderEntryOptions(shipGroupIndex, shippingMethod, shippingInstructions, maySplit, giftMessage, isGift, internalCode, shipBeforeDate, shipAfterDate);
>              this.addErrors(errorMessages, errorMaps, callResult);
>          }
>  
>
> Modified: incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java (original)
> +++ incubator/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java Sat Aug 19 06:55:15 2006
> @@ -1758,6 +1758,11 @@
>      // Ship Group Methods
>      // ----------------------------------------
>  
> +    public int addShipInfo() {
> +        shipInfo.add(new CartShipInfo());
> +        return (shipInfo.size() - 1);
> +    }
> +
>      public List getShipGroups() {
>          return this.shipInfo;
>      }
>
> Modified: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/optionsettings.bsh
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/optionsettings.bsh?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/optionsettings.bsh (original)
> +++ incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/optionsettings.bsh Sat Aug 19 06:55:15 2006
> @@ -27,6 +27,22 @@
>  context.put("cart", cart);
>  productStoreId = ProductStoreWorker.getProductStoreId(request);
>  
> +String shipGroupIndexPar = request.getParameter("shipGroupIndex");
> +String createNewShipGroup = request.getParameter("createNewShipGroup");
> +int shipGroupIndex = 0;
> +if (createNewShipGroup != null && createNewShipGroup.equals("Y")) {
> +    shipGroupIndex = cart.addShipInfo();
> +} else {
> +    if (shipGroupIndexPar != null) {
> +        try {
> +            shipGroupIndex = Integer.parseInt(shipGroupIndexPar);
> +        } catch(Exception exc) {
> +            Debug.logWarning("Unable to parse shipGroupIndex [" + shipGroupIndexPar + "]: " + exc.getMessage());
> +        }
> +    }
> +}
> +context.put("shipGroupIndex", shipGroupIndex);
> +
>  // nuke the event messages
>  request.removeAttribute("_EVENT_MESSAGE_");
>  
> @@ -40,8 +56,8 @@
>  context.put("carrierShipmentMethodList", delegator.findByAndCache("ProductStoreShipmentMethView", UtilMisc.toMap("productStoreId", productStoreId), UtilMisc.toList("sequenceNumber")));
>  context.put("emailList",  ContactHelper.getContactMechByType(orderPartyId, "EMAIL_ADDRESS", false));
>  
> -if (cart.getShipmentMethodTypeId() != null && cart.getCarrierPartyId() != null) {
> -    context.put("chosenShippingMethod", cart.getShipmentMethodTypeId() + '@' + cart.getCarrierPartyId());
> +if (cart.getShipmentMethodTypeId(shipGroupIndex) != null && cart.getCarrierPartyId(shipGroupIndex) != null) {
> +    context.put("chosenShippingMethod", cart.getShipmentMethodTypeId(shipGroupIndex) + '@' + cart.getCarrierPartyId(shipGroupIndex));
>  }    
>  
>  // create the beforeDate for calendar
>
> Modified: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/shipsettings.bsh
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/shipsettings.bsh?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/shipsettings.bsh (original)
> +++ incubator/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/shipsettings.bsh Sat Aug 19 06:55:15 2006
> @@ -26,6 +26,23 @@
>  
>  delegator = request.getAttribute("delegator");
>  cart = session.getAttribute("shoppingCart");
> +
> +String shipGroupIndexPar = request.getParameter("shipGroupIndex");
> +String createNewShipGroup = request.getParameter("createNewShipGroup");
> +int shipGroupIndex = 0;
> +if (createNewShipGroup != null && createNewShipGroup.equals("Y")) {
> +    shipGroupIndex = cart.addShipInfo();
> +} else {
> +    if (shipGroupIndexPar != null) {
> +        try {
> +            shipGroupIndex = Integer.parseInt(shipGroupIndexPar);
> +        } catch(Exception exc) {
> +            Debug.logWarning("Unable to parse shipGroupIndex [" + shipGroupIndexPar + "]: " + exc.getMessage());
> +        }
> +    }
> +}
> +context.put("shipGroupIndex", shipGroupIndex);
> +
>  orderPartyId = cart.getPartyId();
>  context.put("cart", cart);
>  
> @@ -42,6 +59,8 @@
>              context.put("orderPerson", orderPerson);
>              context.put("shippingContactMechList", shippingContactMechList);
>          }
> +        String currShipContactMechId = cart.getShippingContactMechId(shipGroupIndex);
> +        context.put("currShipContactMechId", currShipContactMechId);
>      }
>  } else {
>      // Purchase order
>
> Modified: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/billsettings.ftl
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/billsettings.ftl?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/billsettings.ftl (original)
> +++ incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/billsettings.ftl Sat Aug 19 06:55:15 2006
> @@ -49,7 +49,8 @@
>              <input type="hidden" name="finalizeMode" value="payment"/>
>              <table width="100%" cellpadding="1" cellspacing="0" border="0">
>                <tr>
> -                <td colspan="2">    
> +                <td colspan="2">
> +                  <a href="<@ofbizUrl>setShipping?createNewShipGroup=Y</@ofbizUrl>" class="buttontext">Create New Ship Group</a>
>                    <a href="<@ofbizUrl>setBilling?createNew=Y</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonCreateNew}</a>
>                  </td>
>                </tr>
>
> Modified: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/optionsettings.ftl
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/optionsettings.ftl?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/optionsettings.ftl (original)
> +++ incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/optionsettings.ftl Sat Aug 19 06:55:15 2006
> @@ -19,11 +19,13 @@
>  <table border="0" width='100%' cellspacing='0' cellpadding='0' class='boxoutside'>
>  <tr>
>      <td width='100%'>
> +      <br/>
>        <table width='100%' border='0' cellspacing='0' cellpadding='0' class='boxbottom'>
>          <tr>
>            <td>          
>              <form method="post" action="<@ofbizUrl>finalizeOrder</@ofbizUrl>" name="checkoutsetupform">
> -              <input type="hidden" name="finalizeMode" value="options">              
> +              <input type="hidden" name="finalizeMode" value="options"/>
> +              <input type="hidden" name="shipGroupIndex" value="${shipGroupIndex?if_exists}"/>
>                <table width="100%" cellpadding="1" border="0" cellpadding="0" cellspacing="0">
>                 <#if cart.getOrderType() != "PURCHASE_ORDER">
>                  <#assign shipEstimateWrapper = Static["org.ofbiz.order.shoppingcart.shipping.ShippingEstimateWrapper"].getWrapper(dispatcher, cart, 0)>
> @@ -37,7 +39,7 @@
>                    <td valign="top">                            
>                      <div class='tabletext'>                                                
>                        <#if carrierShipmentMethod.partyId != "_NA_">${carrierShipmentMethod.partyId?if_exists}&nbsp;</#if>${carrierShipmentMethod.description?if_exists}
> -                      <#if cart.getShippingContactMechId()?exists>
> +                      <#if cart.getShippingContactMechId(shipGroupIndex)?exists>
>                          <#assign shippingEst = shipEstimateWrapper.getShippingEstimate(carrierShipmentMethod)?default(-1)>
>                          <#if shippingEst?has_content>
>                            &nbsp;-&nbsp;
> @@ -73,7 +75,7 @@
>                  </tr>
>                  <tr>
>                    <td valign="top">
> -                    <input type='radio' <#if cart.getMaySplit()?default("N") == "N">checked</#if> name='may_split' value='false'>
> +                    <input type='radio' <#if cart.getMaySplit(shipGroupIndex)?default("N") == "N">checked</#if> name='may_split' value='false'>
>                    </td>
>                    <td valign="top">
>                      <div class="tabletext">${uiLabelMap.FacilityWaitEntireOrderReady}</div>
> @@ -81,7 +83,7 @@
>                  </tr>
>                  <tr>
>                    <td valign="top">
> -                    <input <#if cart.getMaySplit()?default("N") == "Y">checked</#if> type='radio' name='may_split' value='true'>
> +                    <input <#if cart.getMaySplit(shipGroupIndex)?default("N") == "Y">checked</#if> type='radio' name='may_split' value='true'>
>                    </td>
>                    <td valign="top">
>                      <div class="tabletext">${uiLabelMap.FacilityShipAvailable}</div>
> @@ -95,7 +97,7 @@
>                  </tr>
>                  <tr>
>                    <td colspan="2">
> -                    <textarea class='textAreaBox' cols="30" rows="3" name="shipping_instructions">${cart.getShippingInstructions()?if_exists}</textarea>
> +                    <textarea class='textAreaBox' cols="30" rows="3" name="shipping_instructions">${cart.getShippingInstructions(shipGroupIndex)?if_exists}</textarea>
>                    </td>
>                  </tr>
>                  <#if cart.getOrderType() != "PURCHASE_ORDER">
> @@ -115,8 +117,8 @@
>                      <#else>
>                      <div>
>                        <span class="head2"><b>${uiLabelMap.OrderIsThisGift}</b></span>
> -                      <input type='radio' <#if cart.getIsGift()?default("Y") == "Y">checked</#if> name='is_gift' value='true'><span class='tabletext'>${uiLabelMap.CommonYes}</span>
> -                      <input type='radio' <#if cart.getIsGift()?default("N") == "N">checked</#if> name='is_gift' value='false'><span class='tabletext'>${uiLabelMap.CommonNo}</span>
> +                      <input type='radio' <#if cart.getIsGift(shipGroupIndex)?default("Y") == "Y">checked</#if> name='is_gift' value='true'><span class='tabletext'>${uiLabelMap.CommonYes}</span>
> +                      <input type='radio' <#if cart.getIsGift(shipGroupIndex)?default("N") == "N">checked</#if> name='is_gift' value='false'><span class='tabletext'>${uiLabelMap.CommonNo}</span>
>                      </div>
>                      </#if>
>                    </td>
> @@ -130,7 +132,7 @@
>                  </tr>
>                  <tr>
>                    <td colspan="2">
> -                    <textarea class='textAreaBox' cols="30" rows="3" name="gift_message">${cart.getGiftMessage()?if_exists}</textarea>
> +                    <textarea class='textAreaBox' cols="30" rows="3" name="gift_message">${cart.getGiftMessage(shipGroupIndex)?if_exists}</textarea>
>                    </td>
>                  </tr>
>                   </#if>
>
> Added: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl?rev=432836&view=auto
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl (added)
> +++ incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl Sat Aug 19 06:55:15 2006
> @@ -0,0 +1,32 @@
> +<#--
> +
> +Copyright 2001-2006 The Apache Software Foundation
> +
> +Licensed under the Apache License, Version 2.0 (the "License"); you may not
> +use this file except in compliance with the License. You may obtain a copy of
> +the License at
> +
> +http://www.apache.org/licenses/LICENSE-2.0
> +
> +Unless required by applicable law or agreed to in writing, software
> +distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
> +WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
> +License for the specific language governing permissions and limitations
> +under the License.
> +-->
> +
> +<#if shipGroupIndex?exists>
> +
> +<#assign targetUri = targetShipGroupUri?default("setShipping")>
> +<div class="tabContainer">
> +<#list 1..cart.getShipGroupSize() as currIndex>
> +    <#assign currShipGroupIndex = currIndex - 1>
> +    <#if shipGroupIndex == currShipGroupIndex>
> +        <#assign classStyle = "tabButtonSelected">
> +    <#else>
> +        <#assign classStyle = "tabButton">
> +    </#if>
> +    <a href="<@ofbizUrl>${targetUri}?shipGroupIndex=${currShipGroupIndex}</@ofbizUrl>" class="${classStyle}">Ship Group #${currIndex}</a>
> +</#list>
> +</div>
> +</#if>
>
> Propchange: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl
> ------------------------------------------------------------------------------
>     svn:eol-style = native
>
> Propchange: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl
> ------------------------------------------------------------------------------
>     svn:keywords = "Date Rev Author URL Id"
>
> Propchange: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipGroupTabBar.ftl
> ------------------------------------------------------------------------------
>     svn:mime-type = text/plain
>
> Modified: incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipsettings.ftl
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipsettings.ftl?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipsettings.ftl (original)
> +++ incubator/ofbiz/trunk/applications/order/webapp/ordermgr/entry/shipsettings.ftl Sat Aug 19 06:55:15 2006
> @@ -105,15 +105,29 @@
>                  </td>
>                </tr>
>                <form method="post" action="<@ofbizUrl>finalizeOrder</@ofbizUrl>" name="checkoutsetupform">
> -                <input type="hidden" name="finalizeMode" value="ship">
> -                                
> +                <input type="hidden" name="finalizeMode" value="ship"/>
> +                <input type="hidden" name="shipGroupIndex" value="${shipGroupIndex?if_exists}"/>
> +
>                  <tr><td colspan="3"><hr class='sepbar'></td></tr>
>                  <#assign i = 0>
>                  <#list shippingContactMechList as shippingContactMech>
>                    <#assign shippingAddress = shippingContactMech.getRelatedOne("PostalAddress")>
> +                  <#if currShipContactMechId?exists>
> +                      <#if currShipContactMechId == shippingContactMech.contactMechId>
> +                        <#assign checkedValue = "checked">
> +                      <#else>
> +                        <#assign checkedValue = "">
> +                      </#if>
> +                  <#else>
> +                      <#if i == 0>
> +                          <#assign checkedValue = "checked">
> +                      <#else>
> +                          <#assign checkedValue = "">
> +                      </#if>
> +                  </#if>
>                    <tr>
>                      <td align="left" valign="top" width="1%" nowrap>
> -                      <input type="radio" name="shipping_contact_mech_id" value="${shippingAddress.contactMechId}" <#if i == 0>checked</#if>>        
> +                      <input type="radio" name="shipping_contact_mech_id" value="${shippingAddress.contactMechId}" ${checkedValue}>
>                      </td>
>                      <td align="left" valign="top" width="99%" nowrap>
>                        <div class="tabletext">
>
> Modified: incubator/ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml
> URL: http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml?rev=432836&r1=432835&r2=432836&view=diff
> ==============================================================================
> --- incubator/ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml (original)
> +++ incubator/ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml Sat Aug 19 06:55:15 2006
> @@ -87,11 +87,15 @@
>                  <set field="stepTitleId" value="OrderOrderEntryShipToSettings"/>
>                  <set field="stepLabelId" value="FacilityShipping"/>
>                  <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/shipsettings.bsh"/>
> +                <set field="targetShipGroupUri" value="setShipping"/>
>              </actions>
>              <widgets>
>                  <decorator-screen name="CommonOrderCheckoutDecorator">
>                      <decorator-section name="body">
>                          <platform-specific>
> +                            <html><html-template location="component://order/webapp/ordermgr/entry/shipGroupTabBar.ftl"/></html>
> +                        </platform-specific>
> +                        <platform-specific>
>                              <html><html-template location="component://order/webapp/ordermgr/entry/shipsettings.ftl"/></html>
>                          </platform-specific>
>                      </decorator-section>
> @@ -130,10 +134,14 @@
>                  <set field="stepTitleId" value="OrderOrderOptionSettings"/>
>                  <set field="stepLabelId" value="CommonOptions"/>
>                  <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/optionsettings.bsh"/>
> +                <set field="targetShipGroupUri" value="setOptions"/>
>              </actions>
>              <widgets>
>                  <decorator-screen name="CommonOrderCheckoutDecorator">
>                      <decorator-section name="body">
> +                        <platform-specific>
> +                            <html><html-template location="component://order/webapp/ordermgr/entry/shipGroupTabBar.ftl"/></html>
> +                        </platform-specific>
>                          <platform-specific>
>                              <html><html-template location="component://order/webapp/ordermgr/entry/optionsettings.ftl"/></html>
>                          </platform-specific>
>
>
>