{{custom_system('NOME_SISTEMA')}} - {{custom_system('NOME_SISTEMA_2')}}

Dados da ocorrência {{ $ocorrencia->codigo }}

Data Abertura: {{ Carbon\Carbon::parse($ocorrencia->created_at)->format('d/m/Y H:i') }}
____________________________________________________________________________________________

Dados do Solicitante

@if($ocorrencia->user_id != null)

Nome: {{ (isset($ocorrencia->user->name) ? $ocorrencia->user->name : '') }}

Email: {{ (isset($ocorrencia->user->email) ? $ocorrencia->user->email : '') }}

@else

Ocorrência anônima

@endif

@if(isset($ocorrencia->user->telefone)) Telefone: {{ (isset($ocorrencia->user->telefone) ? $ocorrencia->user->telefone : '') }} @endif @if(isset($ocorrencia->user->celular)) Celular: {{ (isset($ocorrencia->user->celular) ? $ocorrencia->user->celular : '') }} @endif

Ocorrência:

Mensagem: {{ $ocorrencia->texto }}

Subcategoria: {{ $ocorrencia->subcategoria->nome }}

@if(isset($ocorrencia->rua->nome)) Rua: {{ (isset($ocorrencia->rua->nome) ? $ocorrencia->rua->nome : '') }}   @else @if(isset($ocorrencia->rua_temporaria)) Rua: {{ (isset($ocorrencia->rua_temporaria) ? $ocorrencia->rua_temporaria : '') }}   @endif @endif @if(isset($ocorrencia->numero)) Número: {{ (isset($ocorrencia->numero) ? $ocorrencia->numero : '') }}   @endif Bairro: {{ (isset($ocorrencia->bairro->nome) ? $ocorrencia->bairro->nome : '') }}

@if($ocorrencia->complemento != null)

Complemento: {{ (isset($ocorrencia->complemento) ? $ocorrencia->complemento : '') }}

@endif @if($ocorrencia->ponto_referencia != null)

Ponto de referência: {{ (isset($ocorrencia->ponto_referencia) ? $ocorrencia->ponto_referencia : '') }}

@endif

Ações:

@foreach($ocorrencia->acoes as $key => $acao)

{{ $key + 1 }}º: {{ $acao->nome }} ({{ ($acao->pivot->concluido == 1 ? 'Concluído' : '') }})

@endforeach