Files
medusa-store/integration-tests/modules/__tests__
Riqwan Thamir 15e9787465 feat(types,medusa): add inventory quantity to products endpoint (#7541)
what:

- when inventory_quantity is requested through the API, we calculate the inventory based on sales channels + stock locations and return the total available inventory.

A variant can have multiple inventory items. As an example:

Table: (variant)
  - 4 (required_quantity via link) x legs (inventory item)
  - 2 x table top

Only if all individual inventory items of a variant are available, do we mark the variant as available as a single unit. 

RESOLVES CORE-2187
2024-05-30 13:20:06 +00:00
..