cancel
Showing results for 
Search instead for 
Did you mean: 

Issues with isSalable

Highlighted

Issues with isSalable

I am having an issue with products imported into Magento.  Using M2.3.2 and urapidflow to import.  When looking at the product in the backend Salable Quantity has a number and looks correct.  When I then go to the frontend the add to cart button on the product is missing.  On the category view I have an add to cart button and that triggers 

if (!$product->isSalable()) { 

from vendor/magento/module-quote/Model/Quote.php and returns the error to the front end user.  How can salable quantity show on the backend but not work on the front end?  On the same product if I open in the backend and then click save (or save and exit) it updates the product and its now available on the front end for adding to the cart.  Help is greatly appreciated.

1 REPLY 1
Highlighted

Re: Issues with isSalable

For deciding if to demonstrate the add to truck catches. In any case, we've found in the event that we have 10 of a thing and a client orders 10 (a stock reservation is made making the attractive amount 0) however isSaleable despite everything brings valid back. Endeavoring to add a thing to the truck causes a mistake as this uses the new IsProductSalableForRequestedQtyInterface What is a dependable way (if utilizing MSI) to decide stock levels in phtml? is it undependable to isSaleable any longer or is this an oversight?

snaptube vidmate