- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Add field to a confirmation block message
I need to add a field in my confirmation message in the block. I have my class here
class PMC_Manutention_Model_Observer extends Mage_Adminhtml_Block_Widget_Form_Container
{
public function adminhtmlWidgetContainerHtmlBefore(Varien_Event_Observer $observer) {
$block = $observer->getEvent()->getBlock();
if ($block instanceof Mage_Adminhtml_Block_Sales_Order_View) {
$order = $block->getOrder();
if($order->hasShipments()){
$message = Mage::helper('sales')->__('Are you sure you want to regenerate the stickers and resend the new tracking number to customer?');
$block->addButton('order_Sticker_bouton', array(
'label' => Mage::helper('sales')->__('Print Sticker'),
'onclick' => "confirmSetLocation('{$message}', '{$this->getPrintStickerUrl($order)}')",
));
}
}
}
I need to add a field like this
$block->addField('nb_sticker', 'text', array(
'name' => 'nb_sticker',
'label' => Mage::helper('sales')->__('nb sticker'),
'title' => Mage::helper('sales')->__('nb sticker'),
'required' => true,
));
any idea how to do that?
thanks for advance
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Add field to a confirmation block message
Hi @bakaye
Can you please elaborate what you want to do? Because, the way you are trying to do will not help you add the field.
200+ professional extensions for M1 & M2 with free lifetime updates!
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: Add field to a confirmation block message
hi, you can see more detail here: http://magento.stackexchange.com/questions/85185/add-field-to-a-confirmation-block-message/85186?nor...