Open andriinuts opened 1 year ago
When you are using an inventory module and for example medusa-plugin-meilisearch then in transformer method product -> variants -> inventory_quantity has the wrong value (not from inventory module)
medusa-plugin-meilisearch
transformer
product
variants
inventory_quantity
Medusa version (including plugins): "@medusajs/medusa": "^1.17.3", "@medusajs/inventory": "^1.11.2", "@medusajs/stock-location": "^1.11.1", "medusa-plugin-meilisearch": "^2.0.10"
console.log(product.variants[0].inventory_quantity)
See the correct value of inventory_quantity from the inventory module
transformer: (product) => { console.log(variant.inventory_quantity); return return { id: product.id, title: product.title, } });
up
Bug report
Describe the bug
When you are using an inventory module and for example
medusa-plugin-meilisearch
then intransformer
methodproduct
->variants
->inventory_quantity
has the wrong value (not from inventory module)System information
Medusa version (including plugins): "@medusajs/medusa": "^1.17.3", "@medusajs/inventory": "^1.11.2", "@medusajs/stock-location": "^1.11.1", "medusa-plugin-meilisearch": "^2.0.10"
Steps to reproduce the behavior
medusa-plugin-meilisearch
and addtransformer
functionconsole.log(product.variants[0].inventory_quantity)
Expected behavior
See the correct value of
inventory_quantity
from the inventory moduleCode snippets
transformer: (product) => { console.log(variant.inventory_quantity); return return { id: product.id, title: product.title, } });