Minimum order value and coupon Magento do not have to fight each other

In the standard the possible minimum orders in Magento looks at the “Total Amount” or. subtotal including. Discount coupon. Is thus defined, that until 25 Can be ordered euro and a voucher code to be the sum of 24 Euro fallen, and can not be purchased, because the minimum order value has fallen below.

This is can be annoying.

But there is a way, communicated to Magento, that the subtotal WITHOUT discount for a minimum order value is to be relevant.

For this you open the Address.php in the folder app / code / core / Mage / Sales / Model / Quote (they can now also copy back into the local directory, so you do not overwrite) and searches for

$amount = Mage::getStoreConfig('sales/minimum_order/amount', $storeId);
if ($this->getBaseSubtotalWithDiscount() < $amount) {

return false;

This is then replaced by

$amount = Mage::getStoreConfig('sales/minimum_order/amount', $storeId);
$zeroamount = 0;
if ($this->getBaseSubtotalWithDiscount() == $ Zeroamount) {
return true;
} elseif ($this->getBaseSubtotalWithDiscount() < $amount) {
return false;

The mixture is then no longer subtotal including. Discount but excluding. Taken off for the minimum order amount.

Used in Magento Version 1.5.1.0 Comments? Additions? Notes? Gladly!

Published by Covos

Since 2009 I have been working intensively with Magento. I started with the creation and operation of B2C stores. This was extended through my work in the logistics sector. This resulted first specialized B2E systems. Today I work day-a day with exciting B2C, B2B- and B2E projects and reports in this blog about challenges and give insider tips.

3 comments on “Minimum order value and coupon Magento do not have to fight each other”

  1. Hallo,

    ich denke es ist besser wenn du, statt die Datei nach code/local/Mage zu kopieren einen Rewrite machst. So implementierst du nur die gewünschte Methode neu und kopierst nicht die ganze “Class”.

    Das macht die Wartung, gerade bei einem Upgrade, definitely easier 🙂

    Liebe Grüße

    Tobi

  2. Voucher code with bypassing the minimum order value.

    Thanks for the contribution – in this way I can change the basic setting for the whole shop.

    but I want, that the minimum order value is effectively deactivated only for a special voucher list.

    Background: In a cooperation we distribute vouchers to customers, who can order a bundle item from us free of charge. The contract partner bears the costs. The customer enters the voucher and the costs for goods and shipping go to € 0.-. The customer now receives the message “You have not yet reached the minimum order value”.
    But I don't want to bypass the minimum order value in general, but only for this special shopping cart price rule voucher list.

    1. This is a good question. The o.g. Adaptation will probably not work this easily. One would have to be able to determine shopping cart rules where this is allowed and where this is not allowed. For this purpose, there are basically. Attribute an. Here I think of the rule ID ad hoc, that could be used, which would be very inflexible, as one for each new rule, which you also have to take into account, would have to adapt the code. Alternatively, you could perhaps use the attribute “Priority” use. If you e.g.. says, that only shopping cart price rules get past the minimum order value, which is the priority 1234 have and all others do not.
      Either way you would have to develop a new logic for this, to represent that. Please contact us if necessary – one of our developers will surely find a suitable solution here.

Leave a Reply

Your email address will not be published. Required fields are marked *