Skip to content

Commit c2e4e0a

Browse files
Skip tier prices >= final price
Added a check to skip tier prices that are greater than or equal to the final price.
1 parent 9768f1c commit c2e4e0a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

app/code/core/Mage/Catalog/Helper/Product/Type/Composite.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,10 @@ public function prepareJsonProductConfig($product)
177177
$_tierPrices = [];
178178
$_tierPricesInclTax = [];
179179
foreach ($product->getTierPrice() as $tierPrice) {
180+
// Skip tier prices >= final price
181+
if ((float)$tierPrice['website_price'] >= $_finalPrice) {
182+
continue;
183+
}
180184
$_tierPrices[] = Mage::helper('core')->currency(
181185
Mage::helper('tax')->getPrice($product, (float) $tierPrice['website_price'], false) - $_priceExclTax,
182186
false,

0 commit comments

Comments
 (0)