@extends('layouts.app') @section('title', 'إدارة المحلات والعقود') @section('content')
إدارة المحلات والعقود
@forelse($shops as $shop) @php // Check if rented (we will mock this for now based on if there's any active contract) $activeContract = $shop->contracts()->where('status', 'active')->where('end_date', '>=', now())->first(); @endphp @empty @endforelse
رقم المحل اسم المحل المنطقة (التصنيف) المستأجر الحالي حالة التأجير الإجراءات
{{ $shop->shop_number }} {{ $shop->shop_name }} @if($shop->category) {{ $shop->category->name }} @else غير محدد @endif @if($activeContract)
{{ $activeContract->tenant_name }}
{{ $activeContract->tenant_phone }}
@else شاغر / متاح @endif
@if($activeContract) مؤجر حالياً @else متاح للتأجير @endif
لا يوجد محلات مسجلة حتى الآن
@endsection