@extends('layouts.admin') @section('title', 'Blog Posts') @section('page-title', 'Blog Posts') @section('content')

Blog Posts

{{ $posts->total() }} total posts

@forelse($posts as $post) @empty @endforelse
Title Category Author Status Published Actions
{{ $post->title }}
{{ Str::limit($post->excerpt ?? $post->content, 60) }}
{{ $post->category ?? 'General' }} {{ $post->author->name ?? 'Admin' }} {{ $post->status=='published' ? '✓ Published' : '◷ Draft' }} {{ optional($post->published_at)->format('d M Y') ?? '—' }}
@csrf
@csrf @method('DELETE')
No blog posts yet
@if($posts->hasPages())
{{ $posts->links() }}
@endif @endsection