|
|
Nov '15 |
3 |
602 |
0 |
Controller.php
class Controller extends Controller {
public function customAction(){
$data = [
'id' => 15000,
'type' => 'new_employee'
'whatever' => 'whatever'
];
new \MyApp\Module\Lib\Transfers($data);
}
}
then your cron / queue can be calling /var/www/myapp/modules/mymodule/lib/Transfers.php
?
i use php-resque to send emails ( https://github.com/chrisboulton/php-resque)
i think it is in top 3 solutions out there. Also when you create workers, you dont have to mix the logick with phalcon itself.
I have my workers expecting, email template path, variables for the template, and email/emails. After that the queue jobs takes care of the reset.
I dont see a reason why you have to mix workers with phalcon ?