Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-6940

New ProductPriceType 'SHIPPING_ALLOWANCE' and a new minimumPrice field in ProductStoreShipmentMeth entity

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: Trunk
    • Fix Version/s: 16.11.01
    • Component/s: order, product
    • Labels:
      None
    • Sprint:
      Community Day 2 - 2016

      Description

      New price type "SHIPPING_ALLOWANCE" can be used in the scenarios where default/list prices are comprehensive of the 'Shipping Cost' quota, this price type can help user to set the Shipping Allowance cost he has included in the the product's default/list price and then modify actual shipping cost by reducing the allowance cost from it.

      minimumPrice field can be used to set the the lowest rate for a particular shipping type.

      1. OFBIZ-6940.patch
        8 kB
        Vishal Chhabria

        Activity

        Hide
        vishal.chhabria Vishal Chhabria added a comment -

        Attached the patch for Shipping Allowance implementation.

        Details -
        1) Updated ShippingEstimateWrapper constructor to calculate the total allowance amount for all the products in a particular Shipgroup.

        2) Change loadEstimates() signature to loadEstimates(BigDecimal totalAllowance) to accept the total allowance of a shipgroup.

        3) Modified ShippingEvents.getShipGroupEstimate() method to reduce the shippingAllowance amount from actual Shipping Cost. Also, made changes to check if the totalShipping is greater than minimumPrice for a particular shipping option.

        Show
        vishal.chhabria Vishal Chhabria added a comment - Attached the patch for Shipping Allowance implementation. Details - 1) Updated ShippingEstimateWrapper constructor to calculate the total allowance amount for all the products in a particular Shipgroup. 2) Change loadEstimates() signature to loadEstimates(BigDecimal totalAllowance) to accept the total allowance of a shipgroup. 3) Modified ShippingEvents.getShipGroupEstimate() method to reduce the shippingAllowance amount from actual Shipping Cost. Also, made changes to check if the totalShipping is greater than minimumPrice for a particular shipping option.
        Hide
        jacopoc Jacopo Cappellato added a comment -

        Hi Vishal,

        you have uploaded a wrong patch: this one is probably for another ticket.

        Show
        jacopoc Jacopo Cappellato added a comment - Hi Vishal, you have uploaded a wrong patch: this one is probably for another ticket.
        Hide
        vishal.chhabria Vishal Chhabria added a comment -

        Uploaded correct patch, thanks Jacopo Cappellato for pointing it out.

        Show
        vishal.chhabria Vishal Chhabria added a comment - Uploaded correct patch, thanks Jacopo Cappellato for pointing it out.
        Hide
        jacopoc Jacopo Cappellato added a comment -

        This is a useful feature for example for stores that prefer to "hide" (part of) the shipping cost in the product price: in this way, the customers will get a more accurate feeling of the total purchase cost even before they perform the checkout and the shipping costs are computed (during checkout the shipping costs will be lowered because part of the cost is included in the product cost).
        The implementation of the feature looks good to me.

        Show
        jacopoc Jacopo Cappellato added a comment - This is a useful feature for example for stores that prefer to "hide" (part of) the shipping cost in the product price: in this way, the customers will get a more accurate feeling of the total purchase cost even before they perform the checkout and the shipping costs are computed (during checkout the shipping costs will be lowered because part of the cost is included in the product cost). The implementation of the feature looks good to me.
        Hide
        mridul.pathak Mridul Pathak added a comment -

        I have reviewed the patch as well. It's a nice feature and changes are looking good. I will commit this patch in next couple of days if no concerns are raised.

        Show
        mridul.pathak Mridul Pathak added a comment - I have reviewed the patch as well. It's a nice feature and changes are looking good. I will commit this patch in next couple of days if no concerns are raised.
        Hide
        mridul.pathak Mridul Pathak added a comment -

        Thanks Vishal Chhabria for your contribution. Your patch is in trunk r1748969.

        Show
        mridul.pathak Mridul Pathak added a comment - Thanks Vishal Chhabria for your contribution. Your patch is in trunk r1748969.

          People

          • Assignee:
            mridul.pathak Mridul Pathak
            Reporter:
            vishal.chhabria Vishal Chhabria
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development

                Agile