@php $tab = $tab ?? 'setup'; @endphp {{-- ───── Sub-header / breadcrumb strip ───── --}}
{{ __('Integrations / WhatsApp Catalog') }}
{{ __('Push products into') }} {{ __('WhatsApp chats') }}
@if ($catalog ?? null) {{ strtoupper(str_replace('_', ' ', $catalog->provider)) }} · connected @else Not connected @endif
{{-- ───── Tab strip ───── --}}
@if (session('status'))
{{ session('status') }}
@endif @if ($errors->any())
@foreach ($errors->all() as $e)
{{ $e }}
@endforeach
@endif {{-- ═══════════════════════════════════════════════════════ --}} {{-- ════════════════ SETUP TAB ═════════════════════════════ --}} {{-- ═══════════════════════════════════════════════════════ --}} @if ($tab === 'setup') @include('user.catalog._setup', [ 'catalog' => $catalog ?? null, 'shops' => $shops ?? collect(), 'products' => $products ?? collect(), 'statusBuckets' => $statusBuckets ?? [], 'totalProducts' => $totalProducts ?? 0, ]) {{-- ═══════════════════════════════════════════════════════ --}} {{-- ════════════════ SEND TAB ══════════════════════════════ --}} {{-- ═══════════════════════════════════════════════════════ --}} @elseif ($tab === 'send') @include('user.catalog._send', [ 'catalog' => $catalog ?? null, 'devices' => $devices ?? collect(), 'totalProducts' => $totalProducts ?? 0, 'recentSends' => $recentSends ?? collect(), ]) {{-- ═══════════════════════════════════════════════════════ --}} {{-- ════════════════ COLLECTIONS TAB ═══════════════════════ --}} {{-- ═══════════════════════════════════════════════════════ --}} @elseif ($tab === 'collections') @include('user.catalog._collections', [ 'catalog' => $catalog ?? null, 'sets' => $sets ?? collect(), 'pickProducts' => $pickProducts ?? collect(), 'devices' => $devices ?? collect(), 'totalProducts' => $totalProducts ?? 0, ]) {{-- ═══════════════════════════════════════════════════════ --}} {{-- ════════════════ ACTIVITY TAB ══════════════════════════ --}} {{-- ═══════════════════════════════════════════════════════ --}} @elseif ($tab === 'activity') @include('user.catalog._activity', [ 'recentSends' => $recentSends ?? collect(), ]) @endif