Exemple #1
0
 public function getHeaderHtml()
 {
     $out = parent::getHeaderHtml();
     $sheepla_container = $this->getLayout()->createBlock('Mage_Core_Block_Template', 'sheepla_container', array('template' => 'sheepla/container.phtml'));
     $out .= $sheepla_container->toHtml();
     return $out;
 }
    public function __construct()
    {
        parent::__construct();
        /** @var Adyen_Subscription_Model_Subscription $subscription */
        $subscription = Mage::registry('current_subscription');
        if (!$subscription) {
            return $this;
        }
        $helper = Mage::helper('adyen_subscription');
        $this->_removeButton('reset');
        $this->_removeButton('save');
        $confirm = Mage::helper('adyen_subscription')->__('Are you sure you want to place the order now?');
        $confirm .= ' ' . Mage::helper('adyen_subscription')->__('Order will be automatically created at:');
        $confirm .= ' ' . $subscription->getActiveQuoteAdditional()->getScheduledAtFormatted();
        $js = <<<JS
var confirm = window.confirm('{$confirm}'); if(confirm) { order.submit() }
JS;
        $this->_updateButton('save', 'onclick', $js);
        $this->_addButton('save_scheduled', ['label' => Mage::helper('adyen_subscription')->__('Finish Editing'), 'class' => 'save', 'onclick' => "order.submitSubscription()"], 20);
    }
Exemple #3
0
 /**
  * Prepare form html. Add block for configurable product modification interface
  *
  * @return string
  */
 public function getFormHtml()
 {
     $html = parent::getFormHtml();
     $html .= $this->getLayout()->createBlock('xpos/adminhtml_catalog_product_composite_configure')->toHtml();
     return $html;
 }