@extends('backend.layouts.app') @section('title', 'Photo List') @section('content') @include('backend.module._index-reset-button')

@if ($galleryId) Photos in: {{ ($g = $galleries->firstWhere('gallery_id', $galleryId)) ? ($g->translations->firstWhere('gallery_translation_main', 1)?->gallery_translation_title ?? $g->translations->first()?->gallery_translation_title ?? 'Gallery') : 'Gallery' }} @else All Photos @endif

@if ($galleryId) Back @endif @can('content-photo-list.create') @if ($galleryId) Add Single Bulk Upload @else Create @endif @endcan
@if ($galleryId) @endif
@if(!$galleryId)
Open a gallery from Photo Galleries to view its photos, then drag & drop to reorder.
@elseif($galleryId && count($photos) <= 1)
Add at least 2 photos in this gallery to enable drag & drop reordering.
@endif
@forelse($photos as $photo) @empty @endforelse
# Image Description Gallery Sort Actions
@if($galleryId) @if(count($photos) > 1) @else @endif @else @endif {{ ($photos->currentPage() - 1) * $photos->perPage() + $loop->iteration }} {{ $photo->photo_descr }} {{ Str::limit($photo->photo_descr, 40) ?? '-' }} @php $g = $photo->gallery; @endphp {{ $g->translations->firstWhere('gallery_translation_main', 1)?->gallery_translation_title ?? $g->translations->first()?->gallery_translation_title ?? 'Gallery #' . ($g->gallery_id ?? '?') }} {{ $photo->photo_sort ?? '-' }}
@can('content-photo-list.update') @endcan @can('content-photo-list.delete')
@csrf @method('DELETE')
@endcan

No photos found

Click "Create" to upload your first photo.

{{ $photos->appends(request()->query())->links('vendor.pagination.custom') }}
@endsection @push('scripts') @endpush