You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
How can i query only in-stock products with the medusa-js client? I don't see that kind of filtering capabilities in the StoreGetProductsParams type.
I know that I would be able to handle this logic in the frontend but that would make paging quite tricky since there would be a discrepancy between the displayed paged products and the actually queried pages.
This is a requirement because my client has a series of products with few in stock and when they go out of stock they typically do not come back in stock. The number of out of stock products will quickly exceed the number of in-stock products.
Any ideas are welcome :D
Thanks for all the good work on this project - looking forward to 2.0 :)
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
How can i query only in-stock products with the medusa-js client? I don't see that kind of filtering capabilities in the
StoreGetProductsParams
type.I know that I would be able to handle this logic in the frontend but that would make paging quite tricky since there would be a discrepancy between the displayed paged products and the actually queried pages.
This is a requirement because my client has a series of products with few in stock and when they go out of stock they typically do not come back in stock. The number of out of stock products will quickly exceed the number of in-stock products.
Any ideas are welcome :D
Thanks for all the good work on this project - looking forward to 2.0 :)
Beta Was this translation helpful? Give feedback.
All reactions