@php $tz = config('app.display_timezone'); $statusColors = ['draft' => 'slate', 'submitted' => 'amber', 'accepted' => 'emerald', 'returned' => 'rose', 'cancelled' => 'slate']; @endphp
{{-- Who holds it now --}}

{{ __('Owner now') }}

{{ $opportunity->owner?->name ?? __('Nobody') }}

{{ __('Originator') }}

{{ $opportunity->originator?->name ?? __('Not recorded') }}

{{ __('Never changes on a handover.') }}

{{ __('Handover') }}

{{ $pending ? __('Waiting for :who', ['who' => $pendingTo]) : __('None waiting') }}

@if ($pending)

{{ __(':from to :to', ['from' => $pending->sender?->name ?? __('a former member'), 'to' => $pendingTo]) }}

{{ __('Sent :date. :owner stays the owner until it is accepted.', ['date' => $pending->submitted_at?->copy()->timezone($tz)->format('D j M Y, H:i'), 'owner' => $opportunity->owner?->name ?? __('The sender')]) }}

{{ $pending->brief }}

@if ($canCancel) {{ __('Cancel handover') }} @endif @if ($canRespond) {{ __('Return') }} {{ __('Accept and take it on') }} @endif
@elseif ($canSubmit)

{{ __('Pass this opportunity to another officer, or to Administration for closing. You stay the owner until they accept.') }}

{{ __('Hand over') }}
@endif {{-- Every handover on this opportunity --}}
@forelse ($history as $h) @empty @endforelse
{{ __('Sent') }} {{ __('From and to') }} {{ __('Brief') }} {{ __('Status') }}
{{ $h->submitted_at?->copy()->timezone($tz)->format('j M Y') }} {{ $h->sender?->name ?? __('a former member') }} → {{ $h->recipient?->name ?? __($groups[$h->recipient_group] ?? 'Administration') }}

{{ \Illuminate\Support\Str::limit((string) $h->brief, 200) }}

@if ($h->response_note)

{{ __('Answer: :note', ['note' => $h->response_note]) }}

@endif
{{ __($statuses[$h->status] ?? $h->status) }} @if ($h->responded_at)

{{ $h->respondedBy?->name }}, {{ $h->responded_at->copy()->timezone($tz)->format('j M Y') }}

@endif
@include('livewire.crm.partials.paginator', ['rows' => $history])
{{ __('Hand over this opportunity') }}
{{ __('Cancel') }} {{ __('Send handover') }} {{ __('Sending…') }}
{{ __('Return the handover') }} {{ __('Cancel') }} {{ __('Return it') }}