@extends('layouts.admin') @section('title', 'Bulletin') @section('content')

Bulletin

@if($bulletin->published_at) Un-Publish @else Publish @endif Edit Delete
@csrf @method('put')
@csrf @method('put')
@csrf @method('delete')
ID {{ $bulletin->id }}
State {{ $bulletin->state->name ?? 'N/A' }}
User {{ $bulletin->user->first_name ?? '' }} {{ $bulletin->user->last_name ?? '' }}
Subject {{ $bulletin->subject ?? 'N/A' }}
Body {!! $bulletin->body !!}
Photo @if($bulletin->attachment) @if(in_array($bulletin->attachment_extension, ['jpg', 'png', 'jpeg', 'gif', 'svg'])) {{ $bulletin->subject }} {{--
{{ $bulletin->subject }}
--}} @elseif(in_array($bulletin->attachment_extension, ['pdf']))

Attachment: Download ({{ $bulletin->attachment }})

@elseif(in_array($bulletin->attachment_extension, ['doc', 'docx']))

Attachment: Download ({{ $bulletin->attachment }})

@endif @else

No Attachment

@endif
@endsection @push('scripts') @endpush