Public Member Functions | |
__construct () | |
getHeaderText () |
Definition at line 35 of file Edit.php.
__construct | ( | ) |
Constructor
By default is looking for first argument as array and assignes it as object attributes This behaviour may change in child classes
Reimplemented from Mage_Adminhtml_Block_Widget_Form_Container.
Definition at line 38 of file Edit.php.
00039 { 00040 parent::__construct(); 00041 00042 $this->_objectId = 'id'; 00043 $this->_controller = 'poll_answer'; 00044 00045 if( $this->getRequest()->getParam($this->_objectId) ) { 00046 $answerData = Mage::getModel('poll/poll_answer') 00047 ->load($this->getRequest()->getParam($this->_objectId)); 00048 Mage::register('answer_data', $answerData); 00049 } 00050 00051 $this->_updateButton('back', 'onclick', 'setLocation(\'' . $this->getUrl('*/poll/edit', array('id' => $answerData->getPollId(), 'tab' => 'answers_section')) . '\');'); 00052 $this->_updateButton('save', 'label', Mage::helper('poll')->__('Save Answer')); 00053 $this->_updateButton('delete', 'label', Mage::helper('poll')->__('Delete Answer')); 00054 }
getHeaderText | ( | ) |
Get header text
Reimplemented from Mage_Adminhtml_Block_Widget_Container.
Definition at line 56 of file Edit.php.
00057 { 00058 return Mage::helper('poll')->__("Edit Answer '%s'", $this->htmlEscape(Mage::registry('answer_data')->getAnswerTitle())); 00059 }