walletservice/app/Console/Kernel.php

37 lines
808 B
PHP
Executable File

<?php
namespace App\Console;
use App\Traits\Helper;
use Illuminate\Console\Scheduling\Schedule;
use Laravel\Lumen\Console\Kernel as ConsoleKernel;
class Kernel extends ConsoleKernel
{
use Helper;
/**
* 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)
{
// Tache cron s'execute tous les jours a minuit
$schedule->call(function () {
$this->refundAllNanoCredit();
})->dailyAt('00:00')->runInBackground();
// })->everyMinute()->runInBackground();
}
}