@extends('layouts.superadmin') @section('title', 'ملف حياة العضو (Member 360)') @section('page-title', 'منظومة الذكاء (EES) - ملف حياة العضو (Member 360)') @section('content')
{{-- هيدر --}}

ملف حياة العضو (Member 360)

حضور، غيابات، لايفات، اختبارات، نقاط، وملف Member Care — الكل في شاشة واحدة ضمن الفترة المحددة.

{{-- سطر إحصائيات --}}
عدد الأعضاء في التحليل
{{ (int)($summary['members'] ?? 0) }}
عاليي الخطورة
{{ (int)($summary['high_risk'] ?? 0) }}
يحتاجون تدخل مباشر من الإدارة العليا.
بحاجة متابعة
{{ (int)($summary['needs_followup'] ?? 0) }}
مؤشرات هبوط في الحضور أو التفاعل.
نجوم محتملون
{{ (int)($summary['stars'] ?? 0) }}
يظهر عليهم استقرار ونقاط عالية وملف Care بمستوى Star.
{{-- فلاتر --}}
محسوبة من الحضور، التحذيرات، وملف Member Care.
إعادة ضبط ترتيب افتراضي: عاليي الخطورة أولاً، ثم حسب الحضور، ثم النقاط.
{{-- جدول الأعضاء --}}

الأعضاء ضمن ملف 360

لكل عضو: حضور، غياب، لايفات، اختبارات، نقاط، مستوى خطر، وارتباطه بملف Member Care.

عدد الأعضاء في الجدول: {{ method_exists($rows, 'total') ? $rows->total() : $rows->count() }}
@forelse($rows as $row) @php $name = $row->name ?? $row->username ?? ('#'.$row->id); $role = $row->main_role ?? 'عضو'; $status = $row->status ?? null; $attendance = $row->attendance_rate !== null ? (int)$row->attendance_rate : null; $riskLevel = $row->risk_level ?? 'low'; $riskColor = match ($riskLevel) { 'high' => 'bg-rose-500/15 text-rose-200 border-rose-500/40', 'medium' => 'bg-amber-500/15 text-amber-200 border-amber-500/40', 'star' => 'bg-emerald-500/20 text-emerald-100 border-emerald-500/60', default => 'bg-slate-500/15 text-slate-200 border-slate-500/40', }; $riskLabel = match ($riskLevel) { 'high' => 'عالي', 'medium' => 'متوسط', 'low' => 'منخفض', 'star' => 'Star', default => $riskLevel, }; $careLevel = $row->care_level ?? null; $lastSeen = $row->last_seen_at ? \Carbon\Carbon::parse($row->last_seen_at)->format('Y-m-d H:i') : '—'; @endphp @empty @endforelse
العضو الدور الحضور % غياب بعذر غياب بدون عذر تحذيرات لايفات اختبارات نقاط الفترة إجمالي النقاط مستوى الخطر Member Care آخر تواجد
{{ $name }} @if(!empty($row->username)) {{ '@'.$row->username }} @endif @if($status) حالة الحساب: {{ $status }} @endif @if(!empty($row->email)) {{ $row->email }} @endif
{{ $role }} @if(!is_null($attendance)) {{ $attendance }}% @else غير متاح @endif {{ (int)($row->excused_days ?? 0) }} {{ (int)($row->unexcused_days ?? 0) }} {{ (int)($row->warnings_cnt ?? 0) }} {{ (int)($row->lives_count ?? 0) }} {{ (int)($row->tests_count ?? 0) }} {{ (int)($row->period_points ?? 0) }} نقطة {{ (int)($row->total_points ?? 0) }} نقطة {{ $riskLabel }} @if($careLevel)
ملف Care: {{ $careLevel }} @if(!empty($row->focus_reason)) سبب التركيز: {{ $row->focus_reason }} @endif
@else لا يوجد ملف Care @endif
{{ $lastSeen }}
لا يوجد أعضاء ضمن الشروط الحالية للفلاتر.
@if(method_exists($rows, 'hasPages') && $rows->hasPages())
{{ $rows->links() }}
@endif
{{-- فوتر --}}
الفكرة من Member 360: تعطيك صورة عادلة ومتوازنة عن العضو، مش حكم لحظي من لايف واحد أو غياب واحد.
@endsection