Public Member Functions | |
getSubmitUrl () | |
canSendCommentEmail () | |
Protected Member Functions | |
_beforeToHtml () | |
_prepareLayout () |
Definition at line 34 of file View.php.
_beforeToHtml | ( | ) | [protected] |
Retrieve required options from parent
Reimplemented from Mage_Core_Block_Abstract.
Definition at line 39 of file View.php.
00040 { 00041 if (!$this->getParentBlock()) { 00042 Mage::throwException(Mage::helper('adminhtml')->__('Invalid parrent block for this block')); 00043 } 00044 $this->setEntity($this->getParentBlock()->getSource()); 00045 parent::_beforeToHtml(); 00046 }
_prepareLayout | ( | ) | [protected] |
Prepare child blocks
Reimplemented from Mage_Core_Block_Abstract.
Definition at line 53 of file View.php.
00054 { 00055 $button = $this->getLayout()->createBlock('adminhtml/widget_button') 00056 ->setData(array( 00057 'id' => 'submit_comment_button', 00058 'label' => Mage::helper('sales')->__('Submit Comment'), 00059 'class' => 'save' 00060 )); 00061 $this->setChild('submit_button', $button); 00062 00063 return parent::_prepareLayout(); 00064 }
canSendCommentEmail | ( | ) |
Definition at line 71 of file View.php.
00072 { 00073 switch ($this->getParentType()) { 00074 case 'invoice': 00075 return Mage::helper('sales')->canSendInvoiceCommentEmail($this->getEntity()->getOrder()->getStore()->getId()); 00076 case 'shipment': 00077 return Mage::helper('sales')->canSendShipmentCommentEmail($this->getEntity()->getOrder()->getStore()->getId()); 00078 case 'creditmemo': 00079 return Mage::helper('sales')->canSendCreditmemoCommentEmail($this->getEntity()->getOrder()->getStore()->getId()); 00080 } 00081 00082 return true; 00083 }
getSubmitUrl | ( | ) |