@extends('admin.layout.app') @section('body')

{{ __('admin.course_materials') }}

{{ __('admin.files_video_links_per_course') }}
@if(session('msg'))
{{ session('msg') }}
@endif {{-- Filters --}}
{{ __('admin.reset') }}
@forelse($materials as $m) @empty @endforelse
# {{ __('admin.title') }} {{ __('admin.type_2') }} {{ __('admin.course') }} {{ __('admin.uploaded_by') }} {{ __('admin.actions') }}
{{ $m->id }} {{ $m->title }}
{{ __('admin.created_2') }}: {{ $m->created_at?->format('Y-m-d') }}
@if($m->type === 'file') {{ __('admin.file_2') }} @else {{ __('admin.video') }} @endif {{ $m->course?->title ?? '—' }} @if($m->course?->code) ({{ $m->course->code }}) @endif {{ $m->uploader?->name ?? '—' }}
{{ $m->uploader?->email ?? '' }}
@csrf @method('DELETE')
{{ __('admin.no_materials_found') }}
{{ $materials->withQueryString()->links('pagination::bootstrap-4') }}
@endsection