News:

Support the VirtueMart project and become a member

Main Menu

How to declare a task?

Started by borro, February 13, 2018, 12:00:58 PM

Previous topic - Next topic

borro

Hello!

I'm debugging my code. Now the cursor in the \libraries\legacy\controller\legacy.php and the program check the presense of my own created task in $this->taskMap variable($this is the instance of VirtuemartControllerCategory). How to add my own task to this->taskMap array?
Wish you happiness!

Studio 42

You don't need to add something, taskMap is needed if you use 2 task for 1 function.
Eg apply and save task to use function save
If you overide a controller class and add a new function mytask then it work if you use link task=mytask

borro

Wish you happiness!