Kernel.php 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <?php
  2. namespace App\Console;
  3. use Illuminate\Console\Scheduling\Schedule;
  4. use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
  5. class Kernel extends ConsoleKernel
  6. {
  7. /**
  8. * The Artisan commands provided by your application.
  9. *
  10. * @var array
  11. */
  12. protected $commands = [
  13. \App\Console\Commands\LogExpireDelete::class,
  14. \App\Console\Commands\MakeServiceCommand::class,
  15. \App\Console\Commands\FluxOrderFix::class,
  16. \App\Console\Commands\InventoryDailyLoggingOwner::class,
  17. \App\Console\Commands\WASSyncWMSOrderInformation::class,
  18. \App\Console\Commands\SyncLogCacheTask::class,
  19. \App\Console\Commands\SyncUserVisitMenuLogsCacheTask::class,
  20. ];
  21. /**
  22. * Define the application's command schedule.
  23. *
  24. * @param \Illuminate\Console\Scheduling\Schedule $schedule
  25. * @return void
  26. */
  27. protected function schedule(Schedule $schedule)
  28. {
  29. $schedule->command('LogExpireDelete')->dailyAt('00:01');
  30. $schedule->command('InventoryDailyLoggingOwner')->dailyAt('08:00');
  31. $schedule->command('FluxOrderFix')->hourlyAt(1);
  32. // $schedule->command('FluxOrderFix')->cron('* * * * *');
  33. $schedule->command('WASSyncWMSOrderInformation')->everyMinute();
  34. $schedule->command('syncLogCacheTask')->everyMinute();
  35. $schedule->command('syncUserVisitMenuLogsCacheTask')->everyMinute();
  36. }
  37. /**
  38. * Register the commands for the application.
  39. *
  40. * @return void
  41. */
  42. protected function commands()
  43. {
  44. $this->load(__DIR__ . '/Commands');
  45. require base_path('routes/console.php');
  46. }
  47. }