getEvent()->getBlock(); $isSecure = Mage::app()->getStore()->isCurrentlySecure() ? true : false; if ($block instanceof Mage_Adminhtml_Block_Widget_Grid_Massaction || $block instanceof Enterprise_SalesArchive_Block_Adminhtml_Sales_Order_Grid_Massaction) { if ($block->getRequest()->getControllerName() == 'sales_order' || $block->getRequest()->getControllerName() == 'adminhtml_sales_order') { $block->addItem('delete', array( 'label'=> Mage::helper('gridactions')->__('Delete Order'), 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('delete' => 1, '_secure' => $isSecure)), )); // $block->addItem('invoice', array( // 'label'=> Mage::helper('gridactions')->__('Invoice (notify Customer)'), // 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, 'email' => 1, '_secure' => $isSecure)), // )); // $block->addItem('invoice_without', array( // 'label'=> Mage::helper('gridactions')->__('Invoice (don\'t notify Customer)'), // 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, '_secure' => $isSecure)), // )); $block->addItem('build', array( 'label'=> Mage::helper('gridactions')->__('Build'), 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('build' => 1, '_secure' => $isSecure)), )); // $block->addItem('invoice_build', array( // 'label'=> Mage::helper('gridactions')->__('Invoice / Build (notify Customer)'), // 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, 'build' => 1, 'email'=> 1, '_secure' => $isSecure)), // )); // $block->addItem('invoice_build_without', array( // 'label'=> Mage::helper('gridactions')->__('Invoice / Build (don\'t notify Customer)'), // 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, 'build' => 1, '_secure' => $isSecure)), // )); $block->addItem('ship', array( 'label'=> Mage::helper('gridactions')->__('Ship (notify Customer)'), 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('ship' => 1, 'email'=> 1, '_secure' => $isSecure)), )); $block->addItem('ship_without', array( 'label'=> Mage::helper('gridactions')->__('Ship (don\'t notify Customer)'), 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('ship' => 1, '_secure' => $isSecure)), )); // $block->addItem('invoice_ship', array( // 'label'=> Mage::helper('gridactions')->__('Invoice / Ship (notify Customer)'), // 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, 'ship' => 1, 'email'=> 1, '_secure' => $isSecure)), // )); // $block->addItem('invoice_ship_without', array( // 'label'=> Mage::helper('gridactions')->__('Invoice / Ship (don\'t notify Customer)'), // 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, 'ship' => 1, '_secure' => $isSecure)), // )); $block->addItem('invoice_ship_complete', array( 'label'=> Mage::helper('gridactions')->__('Invoice / Ship / Complete (notify Customer)'), 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, 'ship' => 1, 'complete' => 1, 'email'=> 1, '_secure' => $isSecure)), )); $block->addItem('invoice_ship_complete_without', array( 'label'=> Mage::helper('gridactions')->__('Invoice / Ship / Complete (don\'t notify Customer)'), 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('invoice' => 1, 'ship' => 1, 'complete' => 1, '_secure' => $isSecure)), )); // $block->addItem('complete_without', array( // 'label'=> Mage::helper('gridactions')->__('Complete Order'), // 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/massAction', array('complete' => 1, '_secure' => $isSecure)), // )); $block->addItem('print_lot_traveler', array( 'label'=> Mage::helper('gridactions')->__('Print Lot Traveler'), 'url' => Mage::app()->getStore()->getUrl('gridactions/grid/printLotTraveler', array('_secure' => $isSecure)), )); } } } }