News:

Looking for documentation? Take a look on our wiki

Main Menu

Setting a max number of products results in a zero amount order

Started by cleoni, October 03, 2014, 11:59:18 AM

Previous topic - Next topic

cleoni

Hello,
I am setting up a site built with Virtuemart 2.60, I have noticed the following:

- In a specific product, I have set up a max amount of products that can be put in the cart by editing the Product's details ("Quantity range" fields). The rationale behind is that if one tries to buy say 100 pieces of the item it must be a fake/illegal order, one would contact the company directly for big buys.

Now here's the problem, on the product page, it turns out that I can select a high number of items and put them in the cart (that is, the operation is permitted, I would say it was not)
And here'a an ever stranger effect: the displayed price for the 100 pieces is blank (and not 100 x unit price) and if you try to close the order then VM will not say it is not permitted (as it should) and neither ask for payment method as it does normally, but simply it accepts it as an order which is put in Waiting state.

Is my template buggy or did I miss a configuration on VM behaviour?
Any ideas?
--Cris

GJC Web Design

GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

cleoni

Yes the development site is not publicly accessible, still.

I just hoped someone had tried to use this bultin feature before me and could confirm that at least in his/her install it works. I just need to understand if it's my theme's fault of the plaform's fault.

After inspection of the template (I'm using MJ cart from themeforest) I found absolutely no code on the frontend managing the max-items limits, I am modifying it so that it can handle this feature.
--Cris

jenkinhill

If you want to make a max limit to purchase of 100 then you should simply enter that value for Maximum Purchase Quantity on the product status page. You could even override the language string in the popup that tells the customer they cannot order that number, and include something like "Call us for a large quantity price".

If you don't see the popup whan you place an order larger than the maximum then your template overrides are incorrect and need editing.
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

cleoni

Thank you.

I confirm that the template override managing the cart was not considering at all that field and so I had to patch it.

I thought there was an option somewhere asking "If the quantity > max purchase..." (o) Accept order (o) Refuse order

but now I see it's simply that my template does not perform all the validations it should.

Thanks again

--Cris