getEvent()->getBlock(); if($block instanceof Mage_Adminhtml_Block_Widget_Grid_Massaction && strpos($block->getRequest()->getControllerName(),'sales_order') !== false && Mage::getStoreConfig('easyorderprocessing/settings/active')) { $block->addItem('easyprocess_start', array( 'label'=> Mage::helper('easyorderprocessing')->__('--- EASY ORDER PROCESSING ---'), 'url' => "", ) ); // SHIPPING if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_ship')) { $block->addItem('easyprocess_ship', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Shipment'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 0, 'invoice' => 0, 'invoiceprint' => 0, 'ship' => 1, 'shipprint' => 0, 'capture' => 0, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_ship_shipprint')) { $block->addItem('easyprocess_ship_shipprint', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Shipment + Print'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 0, 'invoice' => 0, 'invoiceprint' => 0, 'ship' => 1, 'shipprint' => 1, 'capture' => 0, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_ship_pacsoft')) { $block->addItem('easyprocess_ship_pacsoft', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Shipment + Pacsoft'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 0, 'invoice' => 0, 'invoiceprint' => 0, 'ship' => 1, 'shipprint' => 0, 'capture' => 0, 'complete' => 0, 'pacsoft' => 1, 'gls' => 0, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_ship_gls')) { $block->addItem('easyprocess_ship_gls', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Shipment + GLS'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 0, 'invoice' => 0, 'invoiceprint' => 0, 'ship' => 1, 'shipprint' => 0, 'capture' => 0, 'complete' => 0, 'pacsoft' => 0, 'gls' => 1, ) ), ) ); } // INVOICE if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_invoice')) { $block->addItem('easyprocess_invoice', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Invoice'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 1, 'invoice' => 1, 'invoiceprint' => 0, 'ship' => 0, 'shipprint' => 0, 'capture' => 0, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_email_invoice_invoiceprint')) { $block->addItem('easyprocess_email_invoice_invoiceprint', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Invoice + Print'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 1, 'invoice' => 1, 'invoiceprint' => 1, 'ship' => 0, 'shipprint' => 0, 'capture' => 0, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_invoice_capture')) { $block->addItem('easyprocess_invoice_capture', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Invoice + Capture'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 1, 'invoice' => 1, 'invoiceprint' => 0, 'ship' => 0, 'shipprint' => 0, 'capture' => 1, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_invoice_capture_invoiceprint')) { $block->addItem('easyprocess_invoice_capture_invoiceprint', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Invoice + Capture + Print'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 1, 'invoice' => 1, 'invoiceprint' => 1, 'ship' => 0, 'shipprint' => 0, 'capture' => 1, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } // CAPTURE if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_capture')) { $block->addItem('easyprocess_capture', array( 'label'=> Mage::helper('easyorderprocessing')->__('Capture All Invoices on Order'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 0, 'invoice' => 0, 'invoiceprint' => 0, 'ship' => 0, 'shipprint' => 0, 'capture' => 1, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } // MULTI PURPOSE if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_invoice_ship_capture_pacsoft')) { $block->addItem('easyprocess_invoice_ship_capture_pacsoft', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Invoice + Capture + Shipment + Pacsoft'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 1, 'invoice' => 1, 'invoiceprint' => 0, 'ship' => 1, 'shipprint' => 0, 'capture' => 1, 'complete' => 0, 'pacsoft' => 1, 'gls' => 0, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_invoice_ship_capture_gls')) { $block->addItem('easyprocess_invoice_ship_capture_gls', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Invoice + Capture + Shipment + GLS'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 1, 'invoice' => 1, 'invoiceprint' => 0, 'ship' => 1, 'shipprint' => 0, 'capture' => 1, 'complete' => 0, 'pacsoft' => 0, 'gls' => 1, ) ), ) ); } if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_email_invoice_ship_capture_complete')) { $block->addItem('easyprocess_email_invoice_ship_capture_complete', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Email + Invoice + Shipment + Capture + Complete'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 1, 'invoice' => 1, 'invoiceprint' => 0, 'ship' => 1, 'shipprint' => 0, 'capture'=>1, 'complete' => 1, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); } /* $block->addItem('easyprocess_test', array( 'label'=> Mage::helper('easyorderprocessing')->__('Create Shipment Print'), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 0, 'invoice' => 0, 'invoiceprint' => 0, 'ship' => 0, 'shipprint' => 1, 'capture' => 0, 'complete' => 0, 'pacsoft' => 0, 'gls' => 0, ) ), ) ); */ /* if(Mage::getStoreConfig('easyorderprocessing/settings/easyprocess_')) { $block->addItem('easyprocess_', array( 'label'=> Mage::helper('easyorderprocessing')->__(''), 'url' => Mage::helper('adminhtml')->getUrl('adminhtml/adminhtml_easyOrderProcessing_grid/process', array( 'email' => 0, 'invoice' => 0, 'ship' => 0, 'capture' => 0, 'complete' => 0, 'pacsoft' => 0, ) ), ) ); } */ //---Ordrebehandling (Fakturer) //Ordrebehandling (Fakturer + udskriv faktura) //--Ordrebehandling (Lav levering) //--Ordrebehandling (Fakturer + lav levering) //Ordrebehandling (Udskriv levering) //--Ordrebehandling (Lav levering + Pacsoft label) //--Ordrebehandling (Fakturer + lav levering + Pacsoft label) //Ordrebehandling (Lav levering + GLS CSV) //Ordrebehandling (Fakturering + Lav levering + GLS CSV) $block->addItem('easyprocess_end', array( 'label'=> Mage::helper('easyorderprocessing')->__('--- ---- ----- ---------- ---'), 'url' => "", ) ); } } }