Wednesday, April 12, 2017

Is it possible to merge this two Task Scheduler - Laravel

I want to merge this two schedule to one single schedule. First Schedule runs for 17 mins everyday from 10:29 am to 10:45 pm. And second one runs for 17 mins between 14:59 pm to 15:15 pm everyday. Each of them run every minute. Same time zone and same command.

Can I have something like 2 between? What is the elegant way to do this?

 $schedule->command('abcd')->timezone('john_doe')->between('10:29', '10:45')->everyMinute();
 $schedule->command('abcd')->timezone('john_doe')->between('14:59', '15:15')->everyMinute(); 



via Murlidhar Fichadia

Advertisement