fix scadule for getting price

This commit is contained in:
2026-09-02 18:14:32 +03:30
parent 0b1e5c687b
commit 92d8f2e9b3
5 changed files with 149 additions and 67 deletions
@@ -1,23 +0,0 @@
<?php
namespace App\Console\Commands;
use App\Services\ColleagueOrderCallbackService;
use Illuminate\Console\Command;
class PollPendingColleagueOrdersCommand extends Command
{
protected $signature = 'colleague:poll-pending-orders';
protected $description = 'Poll colleague for pending cover orders every 35s when callback is on';
public function handle(ColleagueOrderCallbackService $service): int
{
$first = $service->pollDueOrders();
sleep(ColleagueOrderCallbackService::POLL_SECONDS);
$second = $service->pollDueOrders();
$this->info(json_encode(['first' => $first, 'second' => $second], JSON_UNESCAPED_UNICODE));
return self::SUCCESS;
}
}
-5
View File
@@ -53,11 +53,6 @@ class Kernel extends ConsoleKernel
->everyMinute()
->name('automations_run')
->withoutOverlapping(50);
$schedule->command('colleague:poll-pending-orders')
->everyMinute()
->name('colleague_poll_pending_orders')
->withoutOverlapping(58);
}
protected function commands()