Jump to content
Yasir88

Minimum total purchase tax incl.

Recommended Posts

Hello guys.

In the back office Preferences ->> Minimum total purchase i can type a number.

Is it possible to type the minimum total purchades with tax incl.?

 

I want the Customers to se that the minimum total purchase is 100kr. tax incl.

 

the tax in denmark is 25%.

 

Thanks for your help

post-247620-0-49743600-1311357170_thumb.jpg

Share this post


Link to post
Share on other sites

Hi Yasir,

I'm sorry we took so long to get back to you. We don't currently offer that feature, but fortunately for you, Denmark's tax rate made it very easy to calculate a workaround. If you have a tax rate of 25% and want a minimum purchase of 100Kr., all you'll need to do is set the minimum purchase at 80Kr., because tax will add another 20Kr. onto the purchase, bringing it up to 100Kr.

 

Please let me know if that works for you.

 

-Mike

Share this post


Link to post
Share on other sites

Maybe I do something wrong, but when I follow your instructions the message for the costumer is (Minimum-Order 50 €):

 

A minimum purchase total of 37,50 € is required in order to validate your order.

 

The message shows the order without the tax.

Share this post


Link to post
Share on other sites

Hi kdk,

Can you post a screenshot of your cart with the error message so that I can check this out for you?

 

-Mike

Share this post


Link to post
Share on other sites

Hi Mike,

 

 

 

thanks for your help.

 

My "target" is a minimum ourchase of 50€ incl. Tax. In the backend i added a minimum purchase of 42, 02€ (19%Tax).

 

But the minmum Order displayed for customers is now 40,02 € - not 50 €

post-16591-0-02914500-1318411844_thumb.png

 

When i add 50 € in the backend and order for less then 59,50€ I have the same situation:

 

post-16591-0-19565900-1318412236_thumb.png.

 

I hope my problem is clear now.

 

kdk

Share this post


Link to post
Share on other sites

P.S.: The problem is not that prestashop calculates something wrong. The problem is that prestashops shows a error-message without the tax.

Share this post


Link to post
Share on other sites

Hello Yasir, kdk,

did you finally solve your problem with minimum order with taxe included?? Please let me know.

Regards

Justin

Share this post


Link to post
Share on other sites

Hi

 

Did anybody solve this problem?

 

I'm working on a PS v1.4.5.1 and have exactly the same problem. I set the min. order to (Swedish) 200Kr but the customer gets notified that they need 160Kr (which is the same as without the tax of 25%)

 

Regards

David C

Share this post


Link to post
Share on other sites

I found a very simple solution to the problem. The error message displaying the confusing tax excl. amount needs to be replaced with a custom text, not displaying the value from preferences at all.

 

1. under preferences set the minimum purchase to 75 KR (= the value WITHOUT the tax)

 

2. open controllers/OrderController.php (that's where the message about the minimum purchase is created)

 

3. search for "check minimal amount" and change the lines:

 

$this->errors[] = Tools::displayError('A minimum purchase total of').' '.Tools::displayPrice($minimalPurchase, $currency).

' '.Tools::displayError('is required in order to validate your order.');

 

 

to

 

$this->errors[] = Tools::displayError('You have not reached the order minimum of 100 KR yet!');

  • Like 2

Share this post


Link to post
Share on other sites

Thanks disrupt for giving me the idea :)

 

It is a little bit different on PS 1.5 but in the same files OrderController.php and OrderOpcController.php

Share this post


Link to post
Share on other sites

Hello guys,

 

I have installed Presta 1.6.0.9. I have a better solution then the one above. This solution is working pritty fine as long as you don't want to change the tax rate and as long as you only use one tax rate for the whole shop. So I would love to have a full dynamic solution. Since I am not a programmer I need some help.

 

What I did is:

 

1. open controllers/front/OrderController.php

2. find the line 53: $currency = Currency::getCurrency((int)$this->context->cart->id_currency);

3. add the following lines (for calculating both amounts with tax included) after the above line:

        $minimal_purchase_incl = Tools::convertPrice((float)Configuration::get('PS_PURCHASE_MINIMUM'), $currency) * 1.07;
        $cart_value_incl = $this->context->cart->getOrderTotal(false, Cart::ONLY_PRODUCTS) * 1.07;

 

To use the new set up variables from point 3.

4. find:                   "Tools::displayPrice($minimal_purchase"

and change it into "Tools::displayPrice($minimal_purchase_incl"

 

5. find:                   "Tools::displayPrice($this->context->cart->getOrderTotal(false, Cart::ONLY_PRODUCTS)"

and change it into "Tools::displayPrice($cart_value_incl"

 

6. change the value 1.07 from point 3 to the tax you would like to have, for example

    19% = 1.19 or

      7% = 1.07

 

 

But the problem is, when the tax will rise one day, you need to change it here in that file.

 

So can anyone tell me a way to replace the value 1.07 into a variable? Or maybe there is a function that is calculating the minimum purchasing amount with tax including? I saw some functions like "getTaxes" or "getTotalRate" or "getTaxesAmount". But couldn't use it in a way that worked.

 

So please could anyone give me the last hint to solve this issue?

 

Thank you

 

Mattie

Edited by Tupsta (see edit history)

Share this post


Link to post
Share on other sites

Hello Tupsta,

This is just ot let you know that your solution works like a charm, PS v. 1.5.6.2 - Thank you!

I only have one tax, so not much trouble updating an updated file!

Share this post


Link to post
Share on other sites

Hi guys, any ideas to solve Min. Purchase alert with tax included in 1.7 ?  I tried to apply this workarround but 1.7 structure is different. Thanks

Share this post


Link to post
Share on other sites

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More