@extends('layouts.main.app') @section('head') @include('layouts.main.headersection',[ 'title'=> __('Blogs'), 'buttons'=>[ [ 'name'=>' '.__('Create a blog post'), 'url'=>route('admin.blog.create'), ] ] ]) @endsection @section('content')
{{ $totalPosts }}

{{ __('Total Blogs') }}

{{ $totalActivePosts }}

{{ __('Active Blogs') }}

{{ $totalInActivePosts }}

{{ __('Inactive Blogs') }}

{{ __('Blogs') }}

@foreach($posts ?? [] as $post) @endforeach
{{ __('Title') }} {{ __('Url') }} {{ __('Status') }} {{ __('Created At') }} {{ __('Action') }}
{{ Str::limit($post->title,20) }} {{ Str::limit(url('blog/'.$post->slug),50) }} {{ $post->status == 1 ? __('Active') : __('Draft') }} {{ $post->created_at->format('F-d-Y') }}
@if(count($posts) == 0)
{{ __('!Opps no records found') }}
@endif
@endsection