inventory icon indicating copy to clipboard operation
inventory copied to clipboard

In-Store pickup store selection wrongly loads all available sources

Open ganeddact opened this issue 2 years ago • 1 comments

If Magento has several sources associated with the website stock, and a configurable option is associated with only some of these and not all, if it is put in the cart, during checkout only the sources/stores where it is associated should be visible for it to be picked up. It's instead showing all sources of the website stock. On the contrary, if the same product is added to the cart but from its simple product page, not as an option of the configurable, the list of stores/sources in the checkout will reflect its associations with sources.

I've tracked down the issue to vendor/magento/module-inventory-in-store-pickup-frontend/view/frontend/web/js/view/store-selector.js at line 171, qty_options is null when there's a simple product, and has values when the product is a configurable option. But this should not affect the availability of store selections, it should reflect the association that the product has

Preconditions (*)

  1. Magento 2.4.3-p3
  2. PHP 7.4

Steps to reproduce (*)

  1. Have multiple sources associated with the website stock
  2. Associate a simple product with only one of the sources
  3. Have the simple product to be an option of a configurable product
  4. Add the simple product to the cart from the configurable page
  5. Click the "select store" button in the checkout when choosing the in-store pickup option

Expected result (*)

  1. Only the associated source should be visible in the popup

Actual result (*)

  1. All website sources are shown in the popup

ganeddact avatar Nov 30 '22 09:11 ganeddact

Hi @ganeddact. Thank you for your report. To speed up processing of this issue, make sure that you provided sufficient information.

Add a comment to assign the issue: @magento I am working on this


m2-assistant[bot] avatar Nov 30 '22 09:11 m2-assistant[bot]