File: D:/HostingSpaces/MdnDirecteur/hours.komma.cloud/app/Console/Kernel.php
<?php
namespace App\Console;
use Carbon\Carbon;
use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
class Kernel extends ConsoleKernel
{
/**
* The Artisan commands provided by your application.
*
* @var array
*/
protected $commands = [
Commands\Inspire::class,
Commands\cleanSoftDeletes::class,
Commands\cleanActivities::class,
Commands\autoGenerateProjects::class,
Commands\autoGenerateBalances::class,
Commands\autoGenerateTotalWorkInProgress::class,
];
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
//clean database of all old soft deleted rows
$schedule->command('auto-generate:projects')->dailyAt('05:00');
$schedule->command('cleanup:all')->monthlyOn(1, '05:00');
$schedule->command('cleanup:activities')->yearly();
$schedule->command('auto-generate:balances')->yearly();
$schedule->command('auto-generate:totalWorkInProgress')->hourlyAt(30);
}
/**
* Register the commands for the application.
*
* @return void
*/
protected function commands()
{
$this->load(__DIR__.'/Commands');
// require base_path('routes/console.php');
}
}