File: /home/imensosw/liftcincy.imenso.co/app/Console/Kernel.php
<?php
namespace App\Console;
use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
use Illuminate\Support\Facades\Log;
class Kernel extends ConsoleKernel
{
/**
* The Artisan commands provided by your application.
*
* @var array
*/
protected $commands = [
Commands\OpportunitySignedUpNotify::class,
//Commands\PostEventSurveyTextOfLiveEventAfter24Hours::class,
Commands\ReminderTextOfLiveEvent::class,
];
/*protected $commands = [
'App\Console\Commands\OpportunitySignedUpNotify',
'App\Console\Commands\PostEventSurveyTextOfLiveEventAfter24Hours',
'App\Console\Commands\ReminderTextOfLiveEvent'
];*/
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
// $schedule->command('inspire')
// ->hourly();
Log::info('Notification posteventsurveytextofliveeventafter24hours scheduled at '.date('Y-m-d H:i:s'));
$schedule->command('command:opportunitysignedup')->everyFiveMinutes();
// TRIGGER AT 9AM THE DAY OF A LIVE EVENT (Text message)
$schedule->command('command:remindertextofliveevent')->dailyAt("09:00");
// TRIGGER 24 HOURS AFTER LIVE EVENT (Text message)
//$schedule->command('command:posteventsurveytextofliveeventafter24hours')->everyFiveMinutes();
//->dailyAt('05:00');
}
/**
* Register the commands for the application.
*
* @return void
*/
protected function commands()
{
$this->load(__DIR__.'/Commands');
require base_path('routes/console.php');
}
}