@extends('site.layouts.new.app') @php $summaryText = $documentSummary ?: 'Nenhuma ementa informada para este documento.'; $hasAttachments = $attachments->isNotEmpty(); $hasProcessing = $processingItems->isNotEmpty(); $hasMeetings = $meetingItems->isNotEmpty(); @endphp @push('styles') @endpush @section('site_content')
@include('site.components.materials-tab', [ 'label' => 'Voltar para matérias', 'href' => $backUrl, 'active' => false, ]) @include('site.components.materials-tab', [ 'label' => 'Detalhes do documento', 'href' => request()->fullUrl(), 'active' => true, ])
Ementa

{{ $documentHeadline }}

{{ $primaryAuthor }}

Abrir documento
{!! nl2br(e($summaryText)) !!}
Documento {{ $documentTitle }} {{ $documentNumber }}
Data de publicação {{ $document->date ?? '-' }}
Protocolo {{ $protocolLabel }}
Status {{ $approvalLabel ?: 'Não informado' }}
Última movimentação {{ $updatedLabel }}
Resumo
Destinatário final @if ($destinationNames->isNotEmpty())
@foreach ($destinationNames as $destinationName) {{ $destinationName }} @endforeach
@else

Nenhum destinatário final informado.

@endif
Caixas vinculadas @if ($document->boxes->isNotEmpty())
@foreach ($document->boxes as $box) {{ $box->description ?? ('Caixa #' . $box->id) }} @endforeach
@else

Documento sem caixa vinculada.

@endif
Arquivos e anexos
@if ($hasAttachments)
@foreach ($attachments as $attachment) @endforeach
@else

Nenhum arquivo anexado.

@endif
Tramitação
@if ($hasProcessing)
@foreach ($processingItems as $processingItem)
{{ $processingItem['status'] }} {{ $processingItem['date'] ?: '-' }}
@if (!empty($processingItem['destination_path']))

{{ $processingItem['destination_path']->implode(' -> ') }}

@endif @php $processingMeta = array_filter([ !empty($processingItem['recipient_user']) ? 'Responsável: ' . $processingItem['recipient_user'] : null, !empty($processingItem['recipient_sector']) ? 'Setor: ' . $processingItem['recipient_sector'] : null, !empty($processingItem['deadline']) ? 'Prazo: ' . $processingItem['deadline'] : null, !empty($processingItem['deadline_at']) ? 'Vencimento: ' . $processingItem['deadline_at'] : null, ]); @endphp @if (!empty($processingMeta))
@foreach ($processingMeta as $processingMetaItem) {{ $processingMetaItem }} @endforeach
@endif @if ($processingItem['description']) {{ $processingItem['description'] }} @endif @if (!empty($processingItem['file_href']) || !empty($processingItem['response_document_href']))
@if (!empty($processingItem['file_href']))
{{ $processingItem['file_label'] }}

Arquivo anexado na tramitação

Baixar anexo
@endif @if (!empty($processingItem['response_document_href']))
{{ $processingItem['response_document_label'] }}

Documento vinculado como resposta

Abrir documento
@foreach ($processingItem['response_document_attachments'] as $responseAttachment)
{{ $responseAttachment['title'] }}

Anexo do documento de resposta

Abrir anexo
@endforeach @endif
@endif @if ($processingItem['observation'])
@if ($processingItem['observation_is_long'])
{{ $processingItem['observation_preview'] }} Ver menos
{!! nl2br(e($processingItem['observation'])) !!}
@else {!! nl2br(e($processingItem['observation'])) !!} @endif
@endif
@endforeach
@else

Nenhuma tramitação encontrada.

@endif
Sessões relacionadas
@if ($hasMeetings)
@foreach ($meetingItems as $meetingItem)
{{ $meetingItem['title'] }} @if ($meetingItem['subtitle_is_long'])
{{ $meetingItem['subtitle_preview'] }} Ver menos
{!! nl2br(e($meetingItem['subtitle'])) !!}
@else

{{ $meetingItem['subtitle'] }}

@endif {{ $meetingItem['date'] }}
{{ $meetingItem['action_label'] }} @if (!empty($meetingItem['secondary_action_href']) && !empty($meetingItem['secondary_action_label'])) {{ $meetingItem['secondary_action_label'] }} @endif
@endforeach
@else

Nenhuma sessão relacionada.

@endif
@endsection