@extends('layout.app') @section('title') {{ __('بيانات الدورة') }} @stop @section('content')
{{-- --}}

اسم:

{{ $user->name }}

البريد الالكتروني:

{{ $user->email }}

اسم المستخدم:

{{ $user->user_name }}

رقم الجوال:

{{ $user->phone }}

المسمى الوظيفي:

{{ $user->jobTitle->name ?? 'لم يحدد' }}


@foreach ($user->activities as $activity) @php $status = ''; if (Carbon\Carbon::now()->format('Y-m-d') < $activity->start_date) { $status = 'قادم'; } elseif ( Carbon\Carbon::now()->format('Y-m-d') >= $activity->start_date && Carbon\Carbon::now()->format('Y-m-d') <= $activity->end_date ) { $status = 'قائم'; } elseif ( Carbon\Carbon::now()->format('Y-m-d') > $activity->end_date && $activity->is_active == 1 ) { $status = 'منفذ'; } elseif ( Carbon\Carbon::now()->format('Y-m-d') > $activity->end_date && $activity->is_active == 0 ) { $status = 'غير منفذ'; } elseif ( Carbon\Carbon::now()->format('Y-m-d') > $activity->end_date && $activity->is_active == 2 ) { $status = 'انتهى'; } elseif ( Carbon\Carbon::now()->format('Y-m-d') > $activity->end_date && $activity->is_active == 3 ) { $status = 'منفذ مؤخراً'; } @endphp @endforeach
اسم البرنامج حالة البرنامج تاريخ بدء البرنامج تاريخ انتهاء البرنامج الهدف التفصيلي
{{ $activity->name }} {!! $status !!} {{ Alkoumi\LaravelHijriDate\Hijri::Date('Y-m-d', Carbon\Carbon::parse($activity->start_date)->format('d-m-Y')) }} {{ Alkoumi\LaravelHijriDate\Hijri::Date('Y-m-d', Carbon\Carbon::parse($activity->end_date)->format('d-m-Y')) }} {{ $activity->detailedTarget->name ?? '' }}

@foreach ($user->courses as $course) @php $status = ''; if (Carbon\Carbon::now()->format('Y-m-d') < $course->start_date) { $status = 'قادمة'; } elseif ( Carbon\Carbon::now()->format('Y-m-d') >= $course->start_date && Carbon\Carbon::now()->format('Y-m-d') <= $course->end_date ) { $status = 'قائمة'; } elseif (Carbon\Carbon::now()->format('Y-m-d') > $course->end_date) { $status = 'انتهت'; } @endphp @endforeach
اسم الدورة حالة الدورة تاريخ بدء الدورة تاريخ انتهاء الدورة مشهد الحضور (ان وجد)
{{ $course->title }} {!! $status !!} {{ Alkoumi\LaravelHijriDate\Hijri::Date('Y-m-d', Carbon\Carbon::parse($course->start_date)->format('d-m-Y')) }} {{ Alkoumi\LaravelHijriDate\Hijri::Date('Y-m-d', Carbon\Carbon::parse($course->end_date)->format('d-m-Y')) }} @if ($course->end_date <= Carbon\Carbon::now()->format('Y-m-d')) @if ($course->course_association_id != 1) @php $course_user = App\Models\CourseUser::where([ ['user_id', $user->id], ['course_id', $course->id], ])->first(); @endphp @if ($course_user->presence_from_user && $course_user->status == '1') مشهد الحضور @endif @endif @endif

@foreach ($user->delays as $item) @php $absence_type = ''; $type = ''; if ($item->type == '1') { $type = 'غياب'; $delay_time = 'غياب'; if ($item->absence_type == '0') { $absence_type = 'بعذر'; } elseif ($item->absence_type == '1') { $absence_type = 'بدون عذر'; } } else { $type = 'تأخير'; if ($item->delay_time >= 60) { $minutes = (int) ($item->delay_time % 60); $hours = (int) ($item->delay_time / 60); if ($minutes > 0) { $delay_time = $hours . ' ساعة و ' . $minutes . ' دقيقة'; } else { $delay_time = $hours . ' ساعة'; } } else { $delay_time = $item->delay_time . ' دقيقة'; } $absence_type = 'تأخير'; } @endphp @endforeach
{{ __('التاريخ') }} {{ __('الحالة') }} {{ __('وقت الحضور') }} {{ __('مدة التأخير') }} {{ __('نوع الغياب') }} {{ __('ملاحظة الغياب') }}
{{ Alkoumi\LaravelHijriDate\Hijri::Date('Y-m-d', $item->date) }} {{ $type }} {{ $item->attendees_time ?? 'غياب' }} {{ $delay_time }} {{ $absence_type }} {{ $item->note ?? 'تأخير' }}
@endsection