@extends('layouts.admin') @section('title', 'Review Proposal') @section('page-title', 'Proposal Review Console') @section('content')

Review Proposal

Tinjau proposal pengabdian yang diajukan oleh mahasiswa.

@csrf @method('DELETE')
@if(session('success'))
{{ session('success') }}
@endif @php $existing = \Illuminate\Support\Facades\Storage::disk('public')->files('templates'); $hasTemplate = false; $templateUrl = ''; foreach($existing as $file) { if(str_starts_with(basename($file), 'template-proposal.')) { $hasTemplate = true; $templateUrl = route('template.preview', 'proposal'); break; } } $settingsFile = storage_path('app/deadlines.json'); $deadlines = file_exists($settingsFile) ? json_decode(file_get_contents($settingsFile), true) : []; $currentDeadline = $deadlines['proposal'] ?? ''; @endphp
{{-- Template Upload --}}

Template Proposal

Unggah file panduan mahasiswa.

@csrf
@if($hasTemplate)
Lihat Saat Ini
@csrf @method('DELETE')
@else Belum ada template @endif @error('template_file'){{ $message }}@enderror
{{-- Deadline Settings --}}

Batas Waktu Pengumpulan

Atur tenggat waktu mahasiswa.

@csrf
@if($currentDeadline)
{{ \Carbon\Carbon::parse($currentDeadline)->locale('id')->isoFormat('D MMMM Y') }}
@else Belum ada jadwal ditetapkan @endif
{{-- Desktop Table --}}
@forelse($proposals as $p) @empty @endforelse
IDJudul ProposalMahasiswaDesaStatusSubmittedAksi
P-{{ str_pad($p->id, 4, '0', STR_PAD_LEFT) }} {{ \Illuminate\Support\Str::limit($p->title, 40) }} {{ $p->user->name }} {{ $p->village->name }} {{ ucfirst($p->status) }} {{ $p->created_at->format('d M Y') }}
@if($p->status == 'pending') Review โ†’ @elseif($p->status == 'revision' || $p->status == 'rejected') โณ Revisi @elseif($p->status == 'approved') โœ“ Disetujui @endif
@csrf @method('DELETE')
Belum ada proposal yang diajukan.
{{-- Mobile Cards --}}
@forelse($proposals as $p)
P-{{ str_pad($p->id, 4, '0', STR_PAD_LEFT) }} {{ ucfirst($p->status) }}

{{ \Illuminate\Support\Str::limit($p->title, 50) }}

๐Ÿ‘ค {{ $p->user->name }} ยท ๐Ÿ“ {{ $p->village->name }}
{{ $p->created_at->format('d M Y') }}
@if($p->status == 'pending') Review โ†’ @elseif($p->status == 'approved') โœ“ Disetujui @else โณ Perbaikan @endif
@csrf @method('DELETE')
@empty
Belum ada proposal yang diajukan.
@endforelse
@push('scripts') @endpush @endsection