[Skip to main content](#vessel-content)

#   Product Sold Despite Quantity Reaching Zero

##

- **[YACOps](/forum/user/52764-yacops "View YACOps's Profile")**
- [![YACOps's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/52764-yacops "View YACOps's Profile") Topic Author
- [ Offline](/forum/user/52764-yacops)

Less More

- Posts: 10
- Thank you received: 0
-
-

3 years 7 months ago -  3 years 7 months ago [\#350921](#350921) by [YACOps](/forum/user/52764-yacops "View YACOps's Profile")  *[Product Sold Despite Quantity Reaching Zero](/forum/35-orders-management/906241-product-sold-despite-quantity-reaching-zero#350921 "-- HikaShop version -- : 4.7.2 -- Joomla version -- : 4.2.9 -- Browser(s) name and version -- : Chrome -- Error-message(debug-mod must be tuned on) -- : n.a  This has happened right after the most recent update. I had a product with two variants. One variant (A) was limited to 20 and one ( B ) was unlimited. The overall quantity was set to 30. The product sold out, but then someone was able to purchase an item from variant A, which still had some quantity despite the fact that the overall quantity limit had been reached. I went and checked the product once I realized this order had happened and I was also able to access Variant A despite overall quantity on the product being zero. Variant B, originally set to unlimited, was not available.  Is this a bug or a setting that changed with the update? This is very important to my business as I cannot have items sell once the overall quantity has reached zero. I have used the set up multiple times in the past to allow buyers to purchase an optional but limited item and this has never happened. In the past when overall quantity on a product reaches zero, sales close, and variants do not override overall quantity.")* was created by *[YACOps](/forum/user/52764-yacops "View YACOps's Profile")*

-- HikaShop version -- : 4.7.2
-- Joomla version -- : 4.2.9
-- Browser(s) name and version -- : Chrome
-- Error-message(debug-mod must be tuned on) -- : n.a

This has happened right after the most recent update. I had a product with two variants. One variant (A) was limited to 20 and one ( B ) was unlimited. The overall quantity was set to 30. The product sold out, but then someone was able to purchase an item from variant A, which still had some quantity despite the fact that the overall quantity limit had been reached. I went and checked the product once I realized this order had happened and I was also able to access Variant A despite overall quantity on the product being zero. Variant B, originally set to unlimited, was not available.

Is this a bug or a setting that changed with the update? This is very important to my business as I cannot have items sell once the overall quantity has reached zero. I have used the set up multiple times in the past to allow buyers to purchase an optional but limited item and this has never happened. In the past when overall quantity on a product reaches zero, sales close, and variants do not override overall quantity.

- [ ![Screenshot&#95;20230412-061932.png](/forum/attachment/56880) ](/forum/attachment/56880 "...412-061932.png") [ ](/forum/attachment/56880?download=1 "...412-061932.png")
- [ ![Screenshot&#95;20230412-061940.png](/forum/attachment/56881) ](/forum/attachment/56881 "...412-061940.png") [ ](/forum/attachment/56881?download=1 "...412-061940.png")

Last edit: 3 years 7 months ago by [YACOps](/forum/user/52764-yacops "View YACOps's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM1LW9yZGVycy1tYW5hZ2VtZW50LzkwNjI0MS1wcm9kdWN0LXNvbGQtZGVzcGl0ZS1xdWFudGl0eS1yZWFjaGluZy16ZXJvP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86583
- Thank you received: 14324
-
-

3 years 7 months ago [\#350923](#350923) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Product Sold Despite Quantity Reaching Zero](/forum/35-orders-management/906241-product-sold-despite-quantity-reaching-zero#350923 "-- HikaShop version -- : 4.7.2 -- Joomla version -- : 4.2.9 -- Browser(s) name and version -- : Chrome -- Error-message(debug-mod must be tuned on) -- : n.a  This has happened right after the most recent update. I had a product with two variants. One variant (A) was limited to 20 and one ( B ) was unlimited. The overall quantity was set to 30. The product sold out, but then someone was able to purchase an item from variant A, which still had some quantity despite the fact that the overall quantity limit had been reached. I went and checked the product once I realized this order had happened and I was also able to access Variant A despite overall quantity on the product being zero. Variant B, originally set to unlimited, was not available.  Is this a bug or a setting that changed with the update? This is very important to my business as I cannot have items sell once the overall quantity has reached zero. I have used the set up multiple times in the past to allow buyers to purchase an optional but limited item and this has never happened. In the past when overall quantity on a product reaches zero, sales close, and variants do not override overall quantity.")*

Hi,

As far as I know, it has always been like that.
The quantity of the variant is what is taken into account by the system, if provided. The quantity of the main product is only taken into account if the quantity of the variant is unlimited. In that case, the system considers that it's the main product quantity which should be taken into account.

> In the past when overall quantity on a product reaches zero, sales close, and variants do not override overall quantity.

I don't think this was ever the case. This would only be the case if the quantity of the variants is unlimited.
So if you want the main quantity to be taken into account for all the variants, then you need to set the quantity of all the variants to "unlimited".
As far as I understand, you were just lucky this never happened so far.
To make the system work like you want, it would require the development of a plugin implementing the onAfterProductQuantityCheck event to add a check on the main product quantity.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM1LW9yZGVycy1tYW5hZ2VtZW50LzkwNjI0MS1wcm9kdWN0LXNvbGQtZGVzcGl0ZS1xdWFudGl0eS1yZWFjaGluZy16ZXJvP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.058 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
