{{-- Ongoing incremental sync panel. Rendered ONLY for Shopify integrations that are enabled + Configured. Distinct from the historical sync panel (`_sync-panel.blade.php`) — different controls, different state subtree, different mental model. Required variables in scope: - $integration (App\Models\Integration) - $incrementalSnapshots (array{customers: array, orders: array}) - $canManage (bool) - $isLocal (bool) Methods on parent Livewire component: - enableIncremental(int, string) - disableIncremental(int, string) - runIncrementalNow(int, string) - clearIncrementalError(int, string) - runIncrementalSchedulerNow() --}} @php $incrementalStateLabel = function (?string $state): string { return match ($state) { 'idle' => __('Idle'), 'queued' => __('Queued'), 'syncing' => __('Running…'), 'failed' => __('Failed'), default => __('Idle'), }; }; $incrementalStateColor = function (?string $state): string { return match ($state) { 'idle' => 'zinc', 'queued' => 'zinc', 'syncing' => 'sky', 'failed' => 'red', default => 'zinc', }; }; $iso = fn ($v) => is_string($v) && $v !== '' ? \Illuminate\Support\Carbon::parse($v)->diffForHumans() : null; $resources = [ ['key' => 'customers', 'label' => __('Customers'), 'snap' => $incrementalSnapshots['customers'] ?? []], ['key' => 'orders', 'label' => __('Orders'), 'snap' => $incrementalSnapshots['orders'] ?? []], ]; @endphp
{{ __('Local development only. In production the scheduler runs automatically every 5 minutes via:') }}
php artisan schedule:run
{{ __('(driven by cron).') }}