Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi, what is the best way to get a list of products based on a variant property - specifically I would like all products that have any variants in stock.
You would fetch all products and then use TC.GetVariants( storeId, product, true ) to get the variants for the products and check their stock.
Your can either make your own Classes to "save" the products and their variants or you could just use GetVariants. In GetVariants Tea Commerce will cache the result, so it will go lightning fast the second time you get variants for the same product.
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted