{{ $loop->iteration }} |
@php
$date = \Carbon\Carbon::parse($activity->date);
$days = ['Minggu', 'Senin', 'Selasa', 'Rabu', 'Kamis', 'Jumat', 'Sabtu'];
$months = ['', 'januari', 'februari', 'maret', 'april', 'mei', 'juni', 'juli', 'agustus', 'september', 'oktober', 'november', 'desember'];
$dayName = $days[$date->dayOfWeek];
$monthName = $months[$date->month];
@endphp
{{ $dayName }} {{ $date->format('d') }} {{ $monthName }} {{ $date->format('Y') }}
|
{{ $activity->activity }} |
{{ $activity->location }} |
{{ $activity->coordination }} |
{{ $activity->result }} |
@if($activity->photo_path && file_exists(storage_path('app/public/' . $activity->photo_path)))
@php
$imagePath = storage_path('app/public/' . $activity->photo_path);
$imageData = base64_encode(file_get_contents($imagePath));
$imageType = pathinfo($imagePath, PATHINFO_EXTENSION);
$imageSrc = 'data:image/' . $imageType . ';base64,' . $imageData;
@endphp
@else
-
@endif
|
@endforeach