@extends('admin.layout.layout') @section('content')

Post

@if ($message = Session::get('success')) @endif @if (Session::has('error')) @endif

Post List

@foreach ($voices as $index =>$post) @endforeach
Title Description Category Community Uploaded by Uploaded at Action
{{ $post->title }} {{ substr($post->description, 0, 100) }}... {{ $post->category->name }} {{ $post->name }} {{ $post->uploaded_by }} {{ date('Y-m-d', strtotime($post->created_at)) }} View @if (Auth::id() === $post->user_id) Edit @endif @if($post->user_id != 2) @if($post->status === 0)
@csrf
@csrf
@elseif($post->status === 1) @elseif($post->status === 2) @elseif($post->status === 3) @endif @else
@csrf @method('DELETE') @if (Auth::id() == $post->user_id) @endif
@endif
@endsection