Public Member Functions | |
getQueue () | |
getSaveUrl () | |
getToggleButtonHtml () | |
getSaveButtonHtml () | |
getResetButtonHtml () | |
getBackButtonHtml () | |
getResumeButtonHtml () | |
getIsPreview () | |
getIsTextType () | |
getCanResume () | |
getHeaderText () | |
Protected Member Functions | |
_beforeToHtml () | |
_prepareLayout () |
Definition at line 35 of file Edit.php.
_beforeToHtml | ( | ) | [protected] |
Before rendering html, but after trying to load cache
Reimplemented from Mage_Core_Block_Abstract.
Definition at line 47 of file Edit.php.
00047 { 00048 00049 $this->setTemplate('newsletter/queue/edit.phtml'); 00050 00051 $this->setChild('form', 00052 $this->getLayout()->createBlock('adminhtml/newsletter_queue_edit_form','form') 00053 ); 00054 00055 return parent::_beforeToHtml(); 00056 }
_prepareLayout | ( | ) | [protected] |
Preparing global layout
You can redefine this method in child classes for changin layout
Reimplemented from Mage_Core_Block_Abstract.
Definition at line 63 of file Edit.php.
00064 { 00065 $this->setChild('save_button', 00066 $this->getLayout()->createBlock('adminhtml/widget_button') 00067 ->setData(array( 00068 'label' => Mage::helper('newsletter')->__('Save Newsletter'), 00069 'onclick' => 'queueControl.save()', 00070 'class' => 'save' 00071 )) 00072 ); 00073 00074 $this->setChild('save_and_resume', 00075 $this->getLayout()->createBlock('adminhtml/widget_button') 00076 ->setData(array( 00077 'label' => Mage::helper('newsletter')->__('Save And Resume'), 00078 'onclick' => 'queueControl.resume()', 00079 'class' => 'save' 00080 )) 00081 ); 00082 00083 $this->setChild('reset_button', 00084 $this->getLayout()->createBlock('adminhtml/widget_button') 00085 ->setData(array( 00086 'label' => Mage::helper('newsletter')->__('Reset'), 00087 'onclick' => 'window.location = window.location' 00088 )) 00089 ); 00090 00091 $this->setChild('back_button', 00092 $this->getLayout()->createBlock('adminhtml/widget_button') 00093 ->setData( 00094 array( 00095 'label' => Mage::helper('newsletter')->__('Back'), 00096 'onclick' => "window.location.href = '" . $this->getUrl('*/*') . "'", 00097 'class' => 'back' 00098 ) 00099 ) 00100 ); 00101 00102 $this->setChild('toggle_button', 00103 $this->getLayout()->createBlock('adminhtml/widget_button') 00104 ->setData( 00105 array( 00106 'label' => Mage::helper('newsletter')->__('Toggle Editor'), 00107 'onclick' => 'queueControl.toggleEditor();' 00108 ) 00109 ) 00110 ); 00111 return parent::_prepareLayout(); 00112 }
getBackButtonHtml | ( | ) |
Definition at line 129 of file Edit.php.
00130 { 00131 return $this->getChildHtml('back_button'); 00132 }
getCanResume | ( | ) |
Definition at line 152 of file Edit.php.
00153 { 00154 return in_array($this->getQueue()->getQueueStatus(), array( 00155 Mage_Newsletter_Model_Queue::STATUS_PAUSE 00156 )); 00157 }
getHeaderText | ( | ) |
Definition at line 159 of file Edit.php.
00160 { 00161 return ( $this->getIsPreview() ? Mage::helper('newsletter')->__('View Newsletter') : Mage::helper('newsletter')->__('Edit Newsletter')); 00162 }
getIsPreview | ( | ) |
Definition at line 139 of file Edit.php.
00140 { 00141 return !in_array($this->getQueue()->getQueueStatus(), array( 00142 Mage_Newsletter_Model_Queue::STATUS_NEVER, 00143 Mage_Newsletter_Model_Queue::STATUS_PAUSE 00144 )); 00145 }
getIsTextType | ( | ) |
getQueue | ( | ) |
Retrieve current Newsletter Queue Object
Definition at line 42 of file Edit.php.
00043 { 00044 return Mage::registry('current_queue'); 00045 }
getResetButtonHtml | ( | ) |
Definition at line 124 of file Edit.php.
00125 { 00126 return $this->getChildHtml('reset_button'); 00127 }
getResumeButtonHtml | ( | ) |
Definition at line 134 of file Edit.php.
00135 { 00136 return $this->getChildHtml('save_and_resume'); 00137 }
getSaveButtonHtml | ( | ) |
Definition at line 119 of file Edit.php.
00120 { 00121 return $this->getChildHtml('save_button'); 00122 }
getSaveUrl | ( | ) |
Definition at line 58 of file Edit.php.
00059 { 00060 return $this->getUrl('*/*/save',array('id'=>$this->getRequest()->getParam('id'))); 00061 }
getToggleButtonHtml | ( | ) |
Definition at line 114 of file Edit.php.
00115 { 00116 return $this->getChildHtml('toggle_button'); 00117 }