I am working on a project to display the first Tier Price as the default Price for a Magento
website. Following is what I have done so far:
edited the price.phtml
file
replaced
$_product = $this->getProduct();
with
$_product = $this->getTierPrice($quantity);
On line 44
I tested this out and this isn't working the way I expected. Am I missing something?
Oh, just to check at the start, your code is like this, yes?:
$_product = $this->getProduct(); //$this is Mage_Catalog_Block_Product_Abstract
$price = $_product->getTierPrice($quantity); //$_product is Mage_Catalog_Model_Product
So with the variable $_product
representing the actual product model, can you tell us what value is returned from these function calls:
$dummyPrice = $this->getTierPrice($quantity);
$dummyPrice = $this->getTierPrice(1);
$dummyPrice = $this->getTierPrice(); //should return an array of the tiers
$dummyPrice = $this->getFormatedTierPrice(1);
$dummyPrice = $this->getFormatedTierPrice();//should return an array of the tiers