Jump to content

Minimum purchase value rule implementation


Recommended Posts

There is an option on the Preferences > Orders tab "Minimum purchase total required in order to validate the order". It is tax excluded though and the price applies to the default currency only. Other currencies will have an adjusted value based on the exchange rate entered on the Localization > Currencies tab.
 
If you want the value to stay the same throughout all currencies, you'll have to edit classes/controllers/ModuleFrontController.php, controllers/front/OrderController.php and controllers/front/OrderOpcController.php and change the following code:
 $minimal_purchase = Tools::convertPrice((float)Configuration::get('PS_PURCHASE_MINIMUM'), $currency);

to:

$minimal_purchase = (float)Configuration::get('PS_PURCHASE_MINIMUM');
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...