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

Detail Pengeluaran #{{ $expense->id }}

{{ $expense->transaction_date ? $expense->transaction_date->format('d M Y') : '-' }}

@csrf @method('DELETE')
@if (session('success'))
{{ session('success') }}
@endif

Informasi Transaksi

Kategori: {{ $expense->category_name ?? ($expense->category ?? '-') }}
Tanggal: {{ $expense->transaction_date ? $expense->transaction_date->format('d M Y') : '-' }}
No. Ref: {{ $expense->reference_number ?? '-' }}

Detail Pengeluaran

Jumlah: {{ $expense->formatted_amount }}
Deskripsi: {{ Str::limit($expense->description ?? '-', 40) }}

Informasi Sistem

Dibuat: {{ $expense->created_at->format('d M Y H:i') }}
Oleh: {{ $expense->creator->name ?? 'Tidak diketahui' }}
@if($expense->updated_at != $expense->created_at)
Diupdate: {{ $expense->updated_at->format('d M Y H:i') }}
@endif

Deskripsi

{{ $expense->description ?? '-' }}

@if($expense->notes)

Catatan

{{ $expense->notes }}

@endif
@if($expense->attachment && file_exists(public_path('storage/' . $expense->attachment)))

Lampiran

Download @php $extension = strtolower(pathinfo($expense->attachment, PATHINFO_EXTENSION)); @endphp @if (in_array($extension, ['jpg', 'jpeg', 'png', 'gif', 'webp']))
Lampiran Gambar Preview
@elseif ($extension === 'pdf')
PDF Document
@endif
@endif @endsection