作者:GregKalek
项目:CommutePo
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->call(function () {
$handler = new App\AlertHandler(new App\Curl());
$handler->sendAlertEmails(env('ALERT_FETCH_RANGE'));
})->thenPing(env('ALERT_SEND_HEARTBEAT'))->everyMinute();
}
作者:roslair
项目:roslair
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->command('inspire')->hourly();
// $schedule->call(function (){
// IpLocation::detectAllLocation();
// })->cron('* * * * *');
}
作者:ardiqghenaty
项目:koptel
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
// $schedule->command('inspire')->hourly();
// $schedule->call('App\Http\Controllers\WelcomeController@testMail')->everyFiveMinutes();
$schedule->call('App\\Http\\Controllers\\API\\ShippingAPIController@autoCheckWaybill')->everyFiveMinutes();
$schedule->call('App\\Http\\Controllers\\API\\MailAPIController@registerInvitationMail')->everyFiveMinutes();
}
作者:armandolazart
项目:amsrental-presupuesto
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
*
* @return void
*/
protected function schedule(Schedule $schedule)
{
$prefix = Carbon::now()->format('Y/m/d/');
$schedule->command('backup:run --only-db --prefix="db/' . $prefix . '"')->hourly();
$schedule->command('backup:run --prefix="files/' . $prefix . '"')->weekly();
$schedule->command('backup:clean')->daily();
}
作者:pkor
项目:webconf-porta
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->command('inspire')->hourly();
//tsipizic check
$schedule->call(function () {
})->everyFiveMinutes();
}
作者:rlacerda8
项目:task-contro
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
// get jobs
$schedule->command('queue:work')->everyFiveMinutes()->withoutOverlapping();
$schedule->command('tasks:pending')->dailyAt('11:00')->withoutOverlapping();
$schedule->command('tasks:pending')->everyMinute()->withoutOverlapping();
}
作者:Legolas00
项目:PaintBudd
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
// $schedule->command('inspire')
// ->hourly();
$schedule->command('alert:artist')->daily()->appendOutputTo('storage\\logs\\sendRep.txt');
//Send mail alerting artist
}
作者:ericmller2
项目:thesportsnew
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
// $schedule->call(function(){
// Reader::index();
// })->everyFiveMinutes();
$schedule->command('news:update')->everyThirtyMinutes()->sendOutputTo(storage_path() . '/logs/news/news_updater.log');
}
作者:HAASLEWE
项目:airboo
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
//Change valid status of all tickets that no longer qualify as valid
$schedule->call(function () {
DB::table('tickets')->where('dateofdeparture', '<=', Carbon::now())->update(['valid' => 0]);
})->everyMinute();
//Decrement credits from users that have newly invalid tickets that are still tradable and mark them untradable once complete
$schedule->call(function () {
$where["valid"] = '0';
$where["tradable"] = '1';
$tickets = DB::table('tickets')->where($where)->get();
foreach ($tickets as $ticket) {
//Determine the credit value on the class of the ticket to set the decrement amount
switch ($ticket->class) {
case 'Economy':
$ticketValue = 1;
break;
case 'Business':
$ticketValue = 2;
break;
case 'First':
$ticketValue = 3;
break;
case 'Premium':
$ticketValue = 4;
break;
default:
$ticketValue = 1;
break;
}
DB::table('credits')->where('user_id', $ticket->user_id)->decrement('trade', $ticketValue);
DB::table('tickets')->where('id', $ticket->id)->update(['tradable' => 0]);
}
})->everyMinute();
}
作者:jlightyea
项目:bootcampin
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->call(function () {
$twitterController = new TwitterController();
$twitterController . daemonServiceTrends();
})->everyFiveMinutes();
}
作者:botchagalup
项目:AreYouDepressed
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->command('inspire')->hourly();
$schedule->call(function () {
\App\Http\Controllers\DepressionController::sendEmail();
})->cron('0 0,4,8,12,16,20 * * *');
}
作者:skibradsha
项目:sailschoolo
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->command('inspire')->hourly();
$schedule->command('ltd:sendscheduled')->everyFiveMinutes();
$schedule->command('ltd:notifynotetaker')->dailyAt('05:00');
$schedule->command('ltd:notifypaused')->dailyAt('05:00');
}
作者:DriesV
项目:landorett
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->call(function () {
Mail::raw('Hi Dries!', function ($message) {
$message->from(env('MAIL_FROM'), env('MAIL_NAME'));
$message->to('driesvanschevensteen@me.com')->subject('Test mail!');
});
})->daily();
$schedule->call(function () {
$expiringAuctions = Auction::getExpiringAuctions();
foreach ($expiringAuctions as $auction) {
$bidders = Bid::getBiddersWithId($auction->id);
$highest = Bid::getHighestBidWithId($auction->id);
$auction->buyer_id = $highest->id;
$auction->save();
foreach ($bidders as $bidWithBidder) {
$bidder = $bidWithBidder->user;
if ($bidder->id = $highest->id) {
Mail::raw('Auction ' . $auction->title . ' ended, you are the highest bidder!', function ($message) use($bidder) {
$message->from(env('MAIL_FROM'), env('MAIL_NAME'));
$message->to($bidder->email)->subject('You are the highest bidder.');
});
} else {
Mail::raw('Auction ' . $auction->title . ' ended, you did not give the highest bid!', function ($message) use($bidder) {
$message->from(env('MAIL_FROM'), env('MAIL_NAME'));
$message->to($bidder->email)->subject("Auction ended, you didn't get it.");
});
}
}
}
})->daily();
}
作者:dwoodar
项目:Iserve
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->command('inspire')->hourly();
$schedule->command('emails:daily')->daily();
$schedule->command('motions:rankgeneration')->hourly();
// if(!$motion->lastestRank || $motion->lastestRank->created_at['carbon']->diffInMinutes($now) >= Setting::get('motion.minutes_between_rank_calculations',60)){
}
作者:ThunderI
项目:SHOP-AP
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
//running queue (every five minutes)
$schedule->command('run:queue QueueCommand')->everyFiveMinutes();
//running queue (every five minutes)
$schedule->command('point:expirequeue PointExpireQueueCommand')->dailyAt('06:00');
}
作者:dsd-meetm
项目:backen
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
//$schedule->command('inspire')
// ->hourly();
$schedule->command('sync:caldav --background')->withoutOverlapping()->everyTenMinutes();
$schedule->command('optimise:meetings --background')->withoutOverlapping()->weekly()->sundays()->at('00:00');
}
作者:Zlo
项目:SkillCompas
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->command('inspire')->hourly();
$schedule->call(function () {
Log::info('attaching new verified skills started');
$skills = Skill::whereNotNull('verified_skill_id')->get();
foreach ($skills as $skill) {
$jobs = Job::whereHas('skills', function ($query) use($skill) {
$query->where('skill_id', $skill->id);
})->whereHas('verifiedSkills', function ($query) use($skill) {
$query->where('verified_skill_id', $skill->verified_skill_id);
}, '<', 1)->get();
foreach ($jobs as $job) {
$job->verifiedSkills()->attach($skill->verified_skill_id);
}
}
})->daily();
$schedule->call(function () {
Log::info('HH parsing started');
$hhGrabber = $this->app['App\\Helpers\\HeadHunterGrabber'];
$job = $this->app['App\\Models\\Job'];
$parser = new Parser([$hhGrabber], $job);
$parser->parse();
})->daily();
}
作者:atrauzz
项目:laravel-drydoc
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->call(function () {
Cache::put('last-cron', new Carbon(), 5);
})->everyMinute();
$schedule->command('inspire')->hourly();
}
作者:roslair
项目:nofetc
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->call(function () {
$manager = new NoFManager();
$manager->run();
})->cron('* * * * *');
}
作者:thomasdol
项目:afrouteWe
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->call(function () {
$trip_ids = Trip::where('departure_date', Carbon::today())->lists('id')->toArray();
Booking::where('status', 'reserved')->whereIn('trip_id', $trip_ids)->delete();
})->everyMinute();
}