Public Member Functions | |
addTotal ($label, $value, $grand=false) | |
Protected Member Functions | |
_beforeToHtml () | |
getTotals () | |
Protected Attributes | |
$_totals = array() |
Definition at line 35 of file Totalbar.php.
_beforeToHtml | ( | ) | [protected] |
Retrieve required options from parent
Reimplemented from Mage_Core_Block_Abstract.
Definition at line 42 of file Totalbar.php.
00043 { 00044 if (!$this->getParentBlock()) { 00045 Mage::throwException(Mage::helper('adminhtml')->__('Invalid parrent block for this block')); 00046 } 00047 $this->setOrder($this->getParentBlock()->getOrder()); 00048 $this->setSource($this->getParentBlock()->getSource()); 00049 $this->setCurrency($this->getParentBlock()->getOrder()->getOrderCurrency()); 00050 00051 foreach ($this->getParentBlock()->getOrderTotalbarData() as $v) { 00052 $this->addTotal($v[0], $v[1], $v[2]); 00053 } 00054 00055 parent::_beforeToHtml(); 00056 }
addTotal | ( | $ | label, | |
$ | value, | |||
$ | grand = false | |||
) |
Definition at line 63 of file Totalbar.php.
00064 { 00065 $this->_totals[] = array( 00066 'label' => $label, 00067 'value' => $value, 00068 'grand' => $grand 00069 ); 00070 return $this; 00071 }
getTotals | ( | ) | [protected] |
$_totals = array() [protected] |
Definition at line 37 of file Totalbar.php.