fix price force refresh 2

This commit is contained in:
2026-06-14 12:33:29 +03:30
parent 1abddfbab8
commit db0cc5f1a6
8 changed files with 246 additions and 120 deletions
+6 -9
View File
@@ -13,15 +13,12 @@ class Kernel extends ConsoleKernel
protected function schedule(Schedule $schedule)
{
// تیک قیمت — هر ۱۰ ثانیه (۶ بار در دقیقه)
$schedule->call(function () {
for ($i = 0; $i < 6; $i++) {
\Illuminate\Support\Facades\Artisan::call('prices:tick');
if ($i < 5) {
sleep(10);
}
}
})->everyMinute()->name('prices_tick_10s')->withoutOverlapping();
// تیک قیمت — ۶ بار در دقیقه با فاصله ۱۰ ثانیه (montzar + zaarbox + محصولات)
// نیاز: * * * * * php artisan schedule:run
$schedule->command('prices:tick-loop --iterations=6 --interval=10')
->everyMinute()
->name('prices_tick_10s')
->withoutOverlapping(58);
$schedule->command('prices:refresh-zaarbox')
->everyThirtyMinutes()