I want to add a checkbox on admin grid in sales order page. I want to have in between "New order Rss" and "export menu".
Having a hard time figuring out how to do this as I am quite new to Magento.
Here is what I have done up to now:
I created a module and from what I have read, I should avoid doing rewrites. So I am trying to work it out with observers.
Here is the config of my module:
<config>
<adminhtml>
<events>
<core_block_abstract_prepare_layout_before>
<observers>
<training_testing>
<type>model</type>
<class>Training_Testing_Model_Observer</class>
<method>coreBlockAbstractPrepareLayoutBefore</method>
</training_testing>
</observers>
</core_block_abstract_prepare_layout_before>
</events>
</adminhtml>
</config>
Here is my observer:
class Training_Testing_Model_Observer {
public function coreBlockAbstractPrepareLayoutBefore(Varien_Event_Observer $event){
$block = $event->getBlock();
if(!isset($block)){
return $this;
}
if($block->getType() =='adminhtml/sales_order_grid'){
// should i set a new admin grid template here??
}
}
}
I am having a hard time trying to figure what should be my next step. Should I set a new template where I check if its the sales order grid block?
Added a link to show exactly where I want to have the checkbox.