Reputation: 921
I am not that knowledgable with the Magento API yet, so I don't know where to search.
I found in the docs getTierPriceHtml($product)
but that doesn't really help me.
So, is there a function that I can call on my $product object (in a template) and check if the product has tier pricing? If there is no a direct function in existence, then a short workaround will also be helpful.
I tried if (getTierPriceHtml($product) != null)....
but that didn't work and is quite an ugly approach anyway.
Upvotes: 3
Views: 3727
Reputation: 15216
Try it with $product->getTierPrices()
. If that returns an empty array it means that it doesn't have any tier prices at all.
Upvotes: 6