{{-- resources/views/pro/itins/index.blade.php --}} @extends('layouts.base') @section('title', __('Itineraries')) @section('content') @php /** @var \Illuminate\Pagination\LengthAwarePaginator|\Illuminate\Support\Collection $itineraries */ $itineraries = $itineraries ?? collect(); $isAdmin = (int)(auth()->id() ?? 0) === 1; $baseName = $isAdmin ? 'admin.itins' : 'pro.itins'; $locale = app()->getLocale(); @endphp
| {{ __('Name') }} | {{ __('Organizer') }} | {{ __('Assignees') }} | {{ __('Points') }} | {{ __('Scheduled date') }} | {{ __('Created') }} | {{ __('Actions') }} |
|---|---|---|---|---|---|---|
|
{{ $it->name }}
@if(!empty($it->society_id))
{{ __('Company ID') }}: {{ $it->society_id }}
@endif
|
{{ $ownerName }}
@if(method_exists($it->owner ?? null, 'societies'))
{{-- First company name if available --}}
{{ $it->owner?->societies?->first()?->name ?? __('No company') }}
@endif
|
{{ $assignees ?: __('No assignees') }} | {{ $pointsCount > 0 ? $pointsCount : '—' }} | {{ $scheduled }} | {{ $created }} | {{-- Edit --}} {{ __('Edit') }} {{-- Map (show itinerary path) --}} {{ __('Map') }} {{-- Delete (confirm) --}} |