@php $boardLabel = $boardSlug !== '' ? optional($boards->firstWhere('slug', $boardSlug))->title ?? $boardSlug : '전체'; $statusLabel = match ($status) { 'published' => '발행', 'scheduled' => '예약', default => '전체', }; @endphp
게시판 {{ $boardLabel }} 상태 {{ $statusLabel }} 전체 {{ $posts->total() }}
@foreach ($boards as $board) @endforeach 검색
@if ($posts->isEmpty()) @else
@foreach ($posts as $post) @php $board = $post->board; $statusVariant = $post->publicationVariant(); $postUrl = route('platform.posts.show', ['board' => $board, 'post' => $post]); $editUrl = route('platform.posts.edit', ['board' => $board, 'post' => $post]); $deleteUrl = route('platform.posts.destroy', ['board' => $board, 'post' => $post]); @endphp
{{ $board?->title ?? '-' }} {{ $post->publicationLabel() }}

{{ $post->title }}

작성자 {{ $post->authorLabel() }}
발행일 {{ $post->publicationLabel() }}
수정일 {{ $post->updatedAtLabel() }}
상태 {{ $post->publicationStateLabel() }}
글 보기 수정
@csrf @method('DELETE') 삭제
@endforeach
@endif