From 626c1dda3e0a9da90db32f5c88d06db35d89a22a Mon Sep 17 00:00:00 2001 From: Charles T Date: Mon, 2 Oct 2023 00:45:34 +0800 Subject: [PATCH] Add (ai gen) --- app/Console/Kernel.php | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php index 8886296..1e99ce3 100644 --- a/app/Console/Kernel.php +++ b/app/Console/Kernel.php @@ -48,14 +48,15 @@ protected function schedule(Schedule $schedule) $nextRun->save(); } } + else + { + $nextRun = new DailyTaskSchedule; + $nextRun->task = 'my-technology'; + $nextRun->next_run_time = now()->addMinutes(rand(0, 1440))->toTimeString(); + $nextRun->save(); + } } - else - { - $nextRun = new DailyTaskSchedule; - $nextRun->task = 'my-technology'; - $nextRun->next_run_time = now()->addMinutes(rand(0, 1440))->toTimeString(); - $nextRun->save(); - } + })->everyMinute();