@if(session('success'))
{{ session('success') }}
@endif @if(session('error'))
{{ session('error') }}
@endif @if ($errors->any())
    @foreach ($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif @php $selectedProducts = []; if (!empty($gallery->products)) { $decoded = is_array($gallery->products) ? $gallery->products : json_decode($gallery->products, true); $selectedProducts = is_array($decoded) ? array_values($decoded) : []; } @endphp
@csrf @method('PUT')
Leave empty if you do not want to change the image
@if($gallery->image_path && file_exists(public_path('storage/' . $gallery->image_path))) Gallery Image @else No Image Available @endif

No products selected
Loading products...