16

I want to apply discount on shipping rate. For example if cart subtotal is greater than $125 then there will be a discount of $17 on the shipping cost. I have created shipping cart rule in admin but the rule gets applied on the cart subtotal, not on the shipping cost. I have selected the options "apply to shipping amount" as yes and "Stop Further Rules Processing" as no.

Do anybody have idea about how I can do this. Any help will really be appreciated.

Thanks in advance.

  • I think that apply to shipping cost is not explained correctly. I also thought that selecting this should apply the discount to the shipping cost but apparently it means that it will apply the discount to "also" the shipping cost. – user26885 Jun 5 '15 at 9:19
7

We did this recently with a sort of hackish use of the sales rule admin panel.

In your rule, under 'actions', in the panel 'Apply the rule only to cart items matching the following conditions', create a condition that can never actually occur. We used sku == 'invalid'. As long as you have selected 'Apply to Shipping Amount', it will take the discount only from the shipping costs. It will not match any items in the cart, though.

  • Note one thing though: it only works if the user estimates the shipping on the cart page (basically, you need a shipping method on the quote when you apply the coupon code; we had our cart setup to automatically apply the cheapest shipping method automatically, so it worked for us). – Laura Aug 19 '15 at 13:54
  • Confirmed working in 1.9 :) – puntable Dec 7 '18 at 11:47
2

This in my mind is a bug in the core calculation that ignores the Apply to Shipping Price flag when processing the discount and applies it to the product and this overrides what it did in processShippingAmount.

http://www.magentocommerce.com/bug-tracking/issue/index/id/250

If you modify app/code/core/Mage/SalesRule/Model/Validator.php in the process function near the top of the foreach loop add in

if ($rule->getApplyToShipping()) {
    continue;
}

This will prevent the process method from trying to apply shopping cart rules with Apply to Shipping Price set to Yes.

0

We are using the Shipping Rules extension to do what it seems you are trying to accomplish. We used this extension to create rules to apply a discount to the shipping total based on the subtotal of the cart. Perhaps this is just what you need.

-1

You can go to Magento Admin panel First Step : Promitions Second Step : Shopping Cart Price Rule Then go to Conditions in Left Side bar Apply a Conditions on that What ever You want For example You want a dicount on Subtotal then Apply If ALL of these conditions are true.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.