@extends('layout.app') @section('title') {{ __('الخطة المدرسية') }} @stop @section('css') @endsection @section('content')
{{-- --}}

الرؤية:

{!! $plan_setting->vision !!}

الرسالة:

{!! $plan_setting->message !!}

مواطن القوة:

{!! $plan_setting->strengths !!}

مواطن الضعف:

{!! $plan_setting->weaknesses !!}

الفرص:

{!! $plan_setting->opportunities !!}

التهديدات:

{!! $plan_setting->threats !!}

البيانات الإحصائية

@php use App\Models\Setting; use App\Models\SchoolInformation; use Illuminate\Support\Facades\Auth; $schoolId = Auth::user()->school_id; $setting = $settings; $stages = SchoolInformation::where('school_id', $schoolId)->limit(2)->get(); $stage1 = $stages->first(); $stage2 = $stages->skip(1)->first(); @endphp @if ($stage1 || $stage2) @if ($stage1) @if ($stage2) @else @endif @endif @if ($stage2) @endif @else @endif
اسم المدرسة معلومات المراحل هاتف المدرسة موقع المدرسة نوع المبنى صلاحيته
المرحلة الرقم الإحصائي تاريخ التأسيس عدد الفصول
{{ $setting->title ?? 'غير متوفر' }}{{ $setting->title ?? 'غير متوفر' }}{{ $stage1->department ?? 'غير متوفر' }} {{ $stage1->statistical_number ?? 'غير متوفر' }} {{ $stage1->founding_date ?? 'غير متوفر' }} {{ $stage1->class_num ?? 'غير متوفر' }} {{ $setting->phone ?? 'غير متوفر' }} {{ $setting->location ?? 'غير متوفر' }} حكومي صالح
{{ $stage2->department ?? 'غير متوفر' }} {{ $stage2->statistical_number ?? 'غير متوفر' }} {{ $stage2->founding_date ?? 'غير متوفر' }} {{ $stage2->class_num ?? 'غير متوفر' }}
لا توجد بيانات للمدرسة.

مرافق المبنى المدرسي

@php use App\Models\BuildingFacility; $facilities = BuildingFacility::where('school_id', $schoolId)->get(); $group1 = $facilities->slice(0, ceil($facilities->count() / 2)); $group2 = $facilities->slice(ceil($facilities->count() / 2)); @endphp @foreach ($group1 as $facility) @endforeach @foreach ($group1 as $facility) @endforeach
{{ $facility->facility_name }}
{{ $facility->count > 0 ? $facility->count : '-' }}
@foreach ($group2 as $facility) @endforeach @foreach ($group2 as $facility) @endforeach
{{ $facility->facility_name }}
{{ $facility->count > 0 ? $facility->count : '-' }}

بيانات مدير المدرسة ووكيلها

@php use App\Models\User; use App\Models\JobTitle; $manager = User::where('school_id', $schoolId) ->where('job_title_id', JobTitle::where('name', 'المدير')->first()->id ?? null) ->first(); $assistant = User::where('school_id', $schoolId) ->where('job_title_id', JobTitle::where('name', 'الوكيل')->first()->id ?? null) ->first(); @endphp @if ($manager) @endif @if ($assistant) @endif @if (!$manager && !$assistant) @endif
طبيعة العمل الاسم آخر مؤهل وتاريخه رقم الجوال تاريخ المباشرة بالمدرسة سنوات الخدمة
المدير {{ $manager->name ?? 'غير متوفر' }} {{ $manager->last_qualification ?? 'غير متوفر' }} ، {{ $manager->date_qualification ?? 'غير متوفر' }} {{ $manager->phone ?? 'غير متوفر' }} {{ $manager->direct_date ?? 'غير متوفر' }} {{ $manager->years_of_service ?? 'غير متوفر' }}
الوكيل {{ $assistant->name ?? 'غير متوفر' }} {{ $assistant->last_qualification ?? 'غير متوفر' }} ، {{ $assistant->date_qualification ?? 'غير متوفر' }} {{ $assistant->phone ?? 'غير متوفر' }} {{ $assistant->direct_date ?? 'غير متوفر' }} {{ $assistant->years_of_service ?? 'غير متوفر' }}
لا توجد بيانات للمدير أو الوكيل في هذه المدرسة.

بيانات بأعداد معلمي المدرسة حسب التخصص

@php use App\Models\Subject; $subjects = App\Models\Subject::all(); @endphp @foreach ($subjects as $subject) @endforeach @php $total = 0; @endphp @foreach ($subjects as $subject) @php $count = $subject->users()->count(); $total += $count; @endphp @endforeach
{{ $subject->name }}المجموع
{{ $count }}{{ $total }}

بيانات بأعداد شاغلي الوظائف الفنية والإدارية

@php // use App\Models\User; // use App\Models\JobTitle; $jobTitles = JobTitle::all(); $jobTitleCounts = $jobTitles->mapWithKeys(function ($jobTitle) use ($schoolId) { $count = User::where('school_id', $schoolId) ->where('job_title_id', $jobTitle->id) ->count(); return [$jobTitle->name => $count]; }); @endphp @foreach ($jobTitleCounts as $jobTitle => $count) @endforeach @foreach ($jobTitleCounts as $count) @endforeach
{{ $jobTitle }}
{{ $count > 0 ? $count : '-' }}

بيانات الفصول وعدد الطلاب

@php use App\Models\Stage; use App\Models\Classa; use App\Models\Student; $stagesData = Stage::with([ 'classas' => function ($query) use ($schoolId) { $query->where('school_id', $schoolId); }, ])->get(); @endphp @foreach ($stagesData as $stage)

{{ $stage->name }}

@foreach ($stage->classas as $class) @endforeach @php $totalStudents = 0; @endphp @foreach ($stage->classas as $class) @php $studentCount = Student::where('class_id', $class->id)->count(); $totalStudents += $studentCount; @endphp @endforeach
الصفوف الدراسية{{ $class->name }}المجموع
عدد الطلاب{{ $studentCount > 0 ? $studentCount : '-' }}{{ $totalStudents }}
@endforeach

العدد الإجمالي لطلاب المدرسة

@php $grandTotalStudents = Student::where('school_id', $schoolId)->count(); @endphp

{{ $grandTotalStudents }}

مجموعات التخصص

@php $subjectsWithTeachers = $subjects->filter(function ($subject) { return $subject->users()->count() > 0; }); @endphp @foreach ($subjectsWithTeachers as $subject) @php $teachers = $subject->users; $count = $teachers->count(); $counter = 1; @endphp @foreach ($teachers as $teacher) @if ($loop->first) @endif @php $counter++; @endphp @endforeach @endforeach
التخصص م اسم المعلم التوقيع
{{ $subject->name }}{{ $counter }} {{ $teacher->name }}

موقع المدرسة بواسطة Google Maps

@if ($plan_setting->map_embed) {!! $plan_setting->map_embed !!} @else

لم يتم تحديد موقع المدرسة بعد.

@endif

أعضاء لجنة التميز

@php use App\Models\CommitteeUser; $committeeMembers = App\Models\CommitteeUser::with('user')->get(); @endphp @forelse ($committeeMembers as $index => $member) @empty @endforelse
م الاسم الوظيفة العمل المكلف به
{{ $index + 1 }} {{ $member->user->name }} {{ $member->user->jobTitle->name ?? 'غير محدد' }} @switch($member->role) @case('leader') رئيساً @break @case('member') عضو @break @case('secretary') مقرر اللجنة @break @default دور غير محدد @endswitch
لا توجد بيانات لعرضها.

قيمنا الحاكمة

{!! $plan_setting->our_values !!}

مصادر بناء الخطة

@php use App\Models\PlanSource; $humanSources = App\Models\PlanSource::where('source_type', 'بشري')->get(); $materialSources = App\Models\PlanSource::where('source_type', 'مادي')->get(); $maxRows = max($humanSources->count(), $materialSources->count()); @endphp @for ($i = 0; $i < $maxRows; $i++) @if (isset($humanSources[$i])) @else @endif @if (isset($materialSources[$i])) @else @endif @endfor
م المصادر البشرية م المصادر المادية
{{ $i + 1 }} {{ $humanSources[$i]->source_name }} {{ $i + 1 }} {{ $materialSources[$i]->source_name }}
@if (count($plan->team) != 0)

فريق الخطة ({{ $plan->name }})

@forelse ($plan->team as $item) @empty @endforelse
الاسم عمله المهمة
{{ $item->name }} {{ $item->position }} {{ $item->mission }}
لا يوجد فريق
@endif @php use App\Models\Activity; $activities = Activity::where('school_id', $schoolId)->get(); @endphp @foreach ($activities as $activity)

الأنشطة والبرامج

اسم البرنامج الإجراءات والأنشطة الفئة المستهدفة مسؤول التنفيذ تاريخ التنفيذ مؤشر الأداء
{{ $activity->name ?? 'غير محدد' }}
    @php $procedures = isset($activity->procedures) ? explode("\n", $activity->procedures) : []; @endphp @if (!empty($procedures)) @foreach ($procedures as $procedure) @php $procedure = trim($procedure); @endphp @if (!empty($procedure))
  • {{ htmlentities(strip_tags($procedure), ENT_QUOTES, 'UTF-8') }}
  • @endif @endforeach @else
  • لا توجد إجراءات متاحة
  • @endif
{{ $activity->targeted->name ?? 'غير محدد' }} {{ $activity->user->name ?? 'غير محدد' }} @if ($activity->status == 1) مستمر @else {{ $activity->classroom ?? 'غير محدد' }} ({{ $activity->week ?? 'غير محدد' }}) @endif {{ $activity->p_indicator ?? 'غير محدد' }}
@endforeach
@endsection