Files
apimacro/app/Console/Kernel.php
2024-05-07 12:17:25 +02:00

49 lines
1.3 KiB
PHP

<?php
namespace App\Console;
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 = [
//
];
/**
* 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('backup:clean')->daily()->at('02:00');
$schedule->command('backup:run')->daily()->at('07:00');
$schedule->command('order:gmupdate')->everyTenMinutes();
$schedule->command('product:gmupdate')->daily()->at('02:00');
$schedule->command('product:used:gmupdate')->daily()->at('04:30');
//$schedule->command('product:updateqta')->hourly()->between('8:00', '00:00')->withoutOverlapping();
$schedule->command('product:updateqta')->everyFiveMinutes()->between('8:00', '00:00')->withoutOverlapping();
}
/**
* Register the commands for the application.
*
* @return void
*/
protected function commands()
{
$this->load(__DIR__.'/Commands');
require base_path('routes/console.php');
}
}