ldc-supportweb/app/Console/Kernel.php

42 lines
979 B
PHP
Raw Normal View History

2020-11-18 10:23:51 +01:00
<?php
namespace App\Console;
2021-09-28 14:53:43 +02:00
use App\Jobs\AutoCloseOldTickets;
use App\Jobs\WarnBeforeAutoCloseTicket;
2020-11-18 10:23:51 +01:00
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
*/
2021-07-23 12:06:08 +02:00
protected $commands = [];
2020-11-18 10:23:51 +01:00
/**
* Define the application's command schedule.
*
2022-03-29 16:57:54 +02:00
* @param \Illuminate\Console\Scheduling\Schedule $schedule
2020-11-18 10:23:51 +01:00
* @return void
*/
protected function schedule(Schedule $schedule)
{
2021-09-28 14:53:43 +02:00
$schedule->job(AutoCloseOldTickets::class)->dailyAt('08:00');
$schedule->job(WarnBeforeAutoCloseTicket::class)->dailyAt('08:05');
2020-11-18 10:23:51 +01:00
}
/**
* Register the commands for the application.
*
* @return void
*/
protected function commands()
{
2021-07-23 12:06:08 +02:00
$this->load(__DIR__ . '/Commands');
2020-11-18 10:23:51 +01:00
require base_path('routes/console.php');
}
}