{{-- resources/views/admin/content/pages/index.blade.php --}} @extends('admin.layouts.app') @section('title', $pageTitle ?? 'الصفحات') @php use Illuminate\Support\Facades\Route; /** @var string $table */ /** @var array $columns */ /** @var \Illuminate\Contracts\Pagination\LengthAwarePaginator $pages */ /** @var array $filters */ $has = fn(string $c) => in_array(strtolower($c), $columns ?? [], true); // استنتاج قائمة اللغات من العناصر الحالية إن وُجد عمود locale $locales = []; if ($has('locale')) { $locales = collect($pages->items())->pluck('locale')->filter()->unique()->values()->all(); } @endphp @section('content')
| # | @endif @if($has('title'))العنوان | @endif @if($has('slug'))السلاق | @endif @if($has('status'))الحالة | @endif @if($has('locale'))اللغة | @endif @if($has('published_at'))تاريخ النشر | @endif @if($has('updated_at'))آخر تحديث | @endifإجراءات | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| #{{ $row->id }} | @endif @if($has('title'))
@if(Route::has('admin.content.pages.edit'))
{{ $row->title ?? '—' }}
@else
{{ $row->title ?? '—' }}
@endif
@if($has('canonical_url') && !empty($row->canonical_url))
{{ $row->canonical_url }}
@elseif($has('slug') && !empty($row->slug))
{{-- رابط الواجهة الأمامية الافتراضي --}}
{{ url('/page/' . $row->slug) }}
@endif
|
@endif
@if($has('slug'))
{{ $row->slug }} |
@endif
@if($has('status'))
@php $badge = [ 'published' => 'success', 'draft' => 'secondary', 'archived' => 'warning', ][$row->status] ?? 'secondary'; @endphp {{ $row->status ?? '—' }} | @endif @if($has('locale')){{ strtoupper($row->locale ?? '-') }} | @endif @if($has('published_at')){{ $row->published_at ? \Illuminate\Support\Carbon::parse($row->published_at)->format('Y-m-d H:i') : '—' }} | @endif @if($has('updated_at')){{ $row->updated_at ? \Illuminate\Support\Carbon::parse($row->updated_at)->format('Y-m-d H:i') : '—' }} | @endif||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
لا توجد صفحات بعد.
@if(Route::has('admin.content.pages.create'))
@endif
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||