@php $report = $getRecord(); $state = $report->workflow_state; $decisions = $report->decisions()->with('notification')->orderBy('workflow_version')->get(); $lastReturn = $decisions->last(fn ($decision) => in_array($decision->action, ['return', 'reject'], true)); $recipient = $state ? app(\App\Domain\QuickReports\WorkflowNotifications::class)->recipient($report) : null; @endphp
{{ $lastReturn->actor_name }} · {{ __('report-workflow.stages.'.$lastReturn->stage) }} · {{ $lastReturn->created_at->format('d/m/Y H:i') }}
{{ $lastReturn->justification }}
{{ $decision->actor_name }} · {{ __('report-workflow.stages.'.$decision->stage) }} · {{ $decision->created_at->format('d/m/Y H:i:s') }}
{{ __('report-workflow.states.'.$decision->from_state) }} → {{ __('report-workflow.states.'.$decision->to_state) }}
{{ __('report-workflow.cycle') }} {{ $decision->review_cycle }} · {{ __('report-workflow.version') }} {{ $decision->workflow_version }}
@if ($decision->justification){{ $decision->justification }}
@endif @if ($decision->notification){{ __('report-workflow.notification') }}: {{ __('report-workflow.notifications.'.$decision->notification->status) }}
@endif