*/ class Mage_Adminhtml_Block_Sales_Order_Totals_Tax extends Mage_Tax_Block_Sales_Order_Tax { /** * Get full information about taxes applied to order * * @return array */ public function getFullTaxInfo() { /** @var $source Mage_Sales_Model_Order */ $source = $this->getOrder(); $taxClassAmount = array(); if ($source instanceof Mage_Sales_Model_Order) { $taxClassAmount = Mage::helper('tax')->getCalculatedTaxes($source); if (empty($taxClassAmount)) { $rates = Mage::getModel('sales/order_tax')->getCollection()->loadByOrder($source)->toArray(); $taxClassAmount = Mage::getSingleton('tax/calculation')->reproduceProcess($rates['items']); } else { $shippingTax = Mage::helper('tax')->getShippingTax($source); $taxClassAmount = array_merge($shippingTax, $taxClassAmount); } } return $taxClassAmount; } /** * Display tax amount * * @return string */ public function displayAmount($amount, $baseAmount) { return Mage::helper('adminhtml/sales')->displayPrices( $this->getSource(), $baseAmount, $amount, false, '
' ); } /** * Get store object for process configuration settings * * @return Mage_Core_Model_Store */ public function getStore() { return Mage::app()->getStore(); } }