@extends('layouts.app') @section('subtitle', 'Dashboard') @push('css') @endpush @section('content_body')
{{ \Carbon\Carbon::now()->translatedFormat('d F Y') }}
{{ \Carbon\Carbon::now()->translatedFormat('l') }}
00:00
WIB
Grafik Pengajuan Surat Per Bulan
@php $profile = \Schema::hasTable('village_profiles') ? \DB::table('village_profiles')->first() : null; $logoPath = $profile && isset($profile->logo) && \Storage::disk('public')->exists($profile->logo) ? asset('storage/' . $profile->logo) : asset('images/logo-nias-utara.jpg'); $namaDesa = $profile && isset($profile->village_name) ? $profile->village_name : 'Desa Siofa Banua'; $kecamatan = $profile && isset($profile->district_name) ? $profile->district_name : 'Hiliserangkai'; $kabupaten = $profile && isset($profile->regency_name) ? $profile->regency_name : 'Nias Utara'; $provinsi = $profile && isset($profile->province_name) ? $profile->province_name : 'Sumatera Utara'; $kadesName = $profile && isset($profile->signer_name) ? $profile->signer_name : 'Ama Gea'; $periodeJabatan = '2024 - 2030'; $kodeDesa = '1275042002'; @endphp
Informasi Desa
Logo Kabupaten
{{ $namaDesa }}
Kec. {{ $kecamatan }}, Kab. {{ $kabupaten }}
Prov. {{ $provinsi }}
Kepala Desa {{ $kadesName }}
Periode Jabatan {{ $periodeJabatan }}
Kode Desa {{ $kodeDesa }}
Status Pengajuan Surat
Menunggu
{{ $totalDiajukan }}
({{ $totalPengajuan > 0 ? round(($totalDiajukan / $totalPengajuan) * 100, 1) : 0 }}%)
Disetujui
{{ $totalDisetujui + $totalSelesai }}
({{ $totalPengajuan > 0 ? round((($totalDisetujui + $totalSelesai) / $totalPengajuan) * 100, 1) : 0 }}%)
Ditolak
{{ $totalDitolak }}
({{ $totalPengajuan > 0 ? round(($totalDitolak / $totalPengajuan) * 100, 1) : 0 }}%)
Demografi Jenis Kelamin
Laki-laki
{{ number_format($totalLakiLaki, 0, ',', '.') }} Jiwa ({{ $totalPenduduk > 0 ? round(($totalLakiLaki / $totalPenduduk) * 100, 1) : 0 }}%)
Perempuan
{{ number_format($totalPerempuan, 0, ',', '.') }} Jiwa ({{ $totalPenduduk > 0 ? round(($totalPerempuan / $totalPenduduk) * 100, 1) : 0 }}%)
Demografi Agama
Kristen
{{ $agamaList['Kristen'] }} Jiwa ({{ $totalPenduduk > 0 ? round(($agamaList['Kristen'] / $totalPenduduk) * 100, 1) : 0 }}%)
Katolik
{{ $agamaList['Katolik'] }} Jiwa ({{ $totalPenduduk > 0 ? round(($agamaList['Katolik'] / $totalPenduduk) * 100, 1) : 0 }}%)
Islam
{{ $agamaList['Islam'] }} Jiwa ({{ $totalPenduduk > 0 ? round(($agamaList['Islam'] / $totalPenduduk) * 100, 1) : 0 }}%)
Pengajuan Terbaru
Lihat Semua
@forelse($pengajuanTerbaru->take(5) as $item) @php $isApproved = in_array($item->status, ['disetujui', 'selesai']); $isRejected = $item->status === 'ditolak'; $statusLabel = 'Menunggu'; $badgeColor = '#F59E0B'; // orange $badgeBg = 'rgba(245, 158, 11, 0.1)'; $iconBg = 'rgba(245, 158, 11, 0.15)'; $iconColor = '#F59E0B'; if ($isApproved) { $statusLabel = 'Disetujui'; $badgeColor = '#10B981'; // green $badgeBg = 'rgba(16, 185, 129, 0.1)'; $iconBg = 'rgba(16, 185, 129, 0.15)'; $iconColor = '#10B981'; } elseif ($isRejected) { $statusLabel = 'Ditolak'; $badgeColor = '#EF4444'; // red $badgeBg = 'rgba(239, 68, 68, 0.1)'; $iconBg = 'rgba(239, 68, 68, 0.15)'; $iconColor = '#EF4444'; } @endphp
{{ $item->jenisSurat->nama_surat ?? 'Pengajuan Surat' }}
{{ $item->suratCetak->nomor_surat ?? $item->nomor_pengajuan }}
{{ $item->penduduk->nama_lengkap ?? 'Warga' }}
{{ $statusLabel }} {{ $item->created_at->diffForHumans() }}
@empty
Tidak ada pengajuan terbaru
@endforelse
@stop @section('css') @parent @stop @section('js') @parent @stop