Mage_Adminhtml_Block_Sales_Order_Totalbar Class Reference

Inheritance diagram for Mage_Adminhtml_Block_Sales_Order_Totalbar:

Mage_Adminhtml_Block_Sales_Order_Abstract Mage_Adminhtml_Block_Widget Mage_Adminhtml_Block_Template Mage_Core_Block_Template Mage_Core_Block_Abstract Varien_Object

List of all members.

Public Member Functions

 addTotal ($label, $value, $grand=false)

Protected Member Functions

 _beforeToHtml ()
 getTotals ()

Protected Attributes

 $_totals = array()


Detailed Description

Definition at line 35 of file Totalbar.php.


Member Function Documentation

_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]

Definition at line 58 of file Totalbar.php.

00059     {
00060         return $this->_totals;
00061     }


Member Data Documentation

$_totals = array() [protected]

Definition at line 37 of file Totalbar.php.


The documentation for this class was generated from the following file:

Generated on Sat Jul 4 17:23:01 2009 for Magento by  doxygen 1.5.8