You've done what you need to up to wiring in your controller.
First you need to declare a route for your controller(s) in the module config XML:
...
<admin>
...
<routers>
<masscustomstatusses>
<use>admin</use>
<args>
<module>VivasIndustries_MassCustomStatusses</module>
<frontName>masscustomstatusses</frontName>
</args>
</masscustomstatusses>
</routers>
...
</admin>
...
Then build the controller:
<?php
class VivasIndustries_MassCustomStatusses_ControllerController
extends Mage_Adminhtml_Controller_Action
{
public function actionAction()
{
// Update status here
// Can fetch selected items with $this->getRequest()->getParam()
die('Looks like it works');
}
}
I've used your naming convention exactly as you have described, though I doubt that's what you really want. Better to use standard Magento convention, with controller named IndexController
and base action named indexAction
. But you should get the idea.
Clear cache and try to run that mass action. The die
statement should run, and fill in the blanks from there.
NOTE: I should point out that you're doing the same thing twice. You are both extending the sales order grid to add a mass action AND injecting it via event observer. As the article you reference points out, those are 2 different ways to do the same thing. You should choose one of those methods, only.
Best Answer
Flow below steps
Step:1
Create file
Ar_Custom.xml
at locationapp\etc\modules
and add below codeStep:2 Create
Observer.php
at locationapp\code\community\Ar\Custom\Model\
Step:3 Create
CustomController.php
file at locationapp\code\community\Ar\Custom\controllers\Adminhtml\CustomController.php
and below codeStep:4 Create
config.xml
file at locationapp\code\community\Ar\Custom\etc
and add below codeStep:5 Flush and refresh all cache in admin end.