@extends('layouts.app') @section('title', $asset->name . ' - DOTS HR Pro') @section('content') @if($asset->is_warranty_expiring_soon)
ضمان هذا الأصل ينتهي خلال 30 يوم ({{ $asset->warranty_expiry->format('Y/m/d') }})
@elseif($asset->is_warranty_expired)
ضمان هذا الأصل منتهي ({{ $asset->warranty_expiry->format('Y/m/d') }})
@endif

بيانات الأصل

{{ $asset->asset_code }}
{{ $asset->category_label }}
{{ $asset->brand ?? '—' }}
{{ $asset->model ?? '—' }}
{{ $asset->serial_number ?? '—' }}
{{ $asset->location ?? '—' }}
@php $statusClass = match($asset->status) { 'available' => 'status-active', 'assigned' => 'status-pending', 'maintenance' => 'status-expired', 'retired' => 'status-draft', default => '', }; @endphp {{ $asset->status_label }}
{{ $asset->condition_label }}

بيانات مالية

{{ $asset->purchase_date?->format('Y/m/d') ?? '—' }}
{{ $asset->purchase_cost ? number_format($asset->purchase_cost, 2) : '—' }}
{{ $asset->warranty_expiry?->format('Y/m/d') ?? '—' }}
{{ $asset->assignments->count() }}
@if($asset->notes)

{{ $asset->notes }}

@endif
@if($asset->status === 'assigned' && $asset->current_assignment)

مُسلّم حالياً إلى: {{ $asset->current_employee->full_name }}

{{ $asset->current_assignment->assigned_date->format('Y/m/d') }}
@if($asset->current_assignment->assignment_notes)
{{ $asset->current_assignment->assignment_notes }}
@endif
@csrf

استرجاع الأصل

@endif @if($asset->status !== 'assigned' && $asset->status !== 'retired')

تسليم الأصل

@csrf
@endif

سجل التسليم والإرجاع

@forelse($asset->assignments->sortByDesc('assigned_date') as $asgn) @empty @endforelse
الموظف تاريخ التسليم تاريخ الإرجاع الحالة حالة الإرجاع سلّم بواسطة
{{ $asgn->employee->full_name }} {{ $asgn->assigned_date->format('Y/m/d') }} {{ $asgn->returned_date?->format('Y/m/d') ?? '—' }} {{ $asgn->status === 'active' ? 'مُسلّم' : 'مُسترجع' }} {{ $asgn->return_condition ? \App\Models\Asset::CONDITION_LABELS[$asgn->return_condition] ?? $asgn->return_condition : '—' }} {{ $asgn->assignedByUser->name ?? '—' }}
لا يوجد سجل تسليم
@endsection