@extends('admin.layouts.home') @section('title', 'Course Enrollments') @section('content')

Enrollments for: {{ $course->title }}

Back to Course
@if(session('success'))
{{ session('success') }}
@endif
@forelse($enrollments as $enrollment) @empty @endforelse
ID Student Email Price Paid Payment Method Transaction ID Enrolled Date Completed
{{ $enrollment->id }} {{ $enrollment->user->name ?? 'N/A' }} {{ $enrollment->user->email ?? 'N/A' }} ${{ number_format($enrollment->price_paid ?? 0, 2) }} {{ $enrollment->payment_method ?? 'N/A' }} {{ $enrollment->transaction_id ?? 'N/A' }} {{ $enrollment->created_at->format('M d, Y') }} @if($enrollment->completed_at) Completed
{{ $enrollment->completed_at->format('M d, Y') }} @else In Progress @endif
No enrollments found
{{ $enrollments->links('pagination::bootstrap-5') }}
@endsection