@foreach($demands as $demand) @if($request->stat) @if(\App\Models\DemandStatusDemand::where('demand_id',$demand->id)->get()->last()->status_demand_id == $request->stat) @endif @else @endif @endforeach
Data Tipo da Demanda Destino / Assunto Status Situação Ações
{{ $demand->created_at->format('d/m/Y H:i:s')}}
61 anos atras
{{ $demand->type_demand->name }}
{{ $demand->protocol }}
{{$demand->secretariat->name}}
{{ $demand->subject }}
{{ \App\Models\DemandStatusDemand::where('demand_id',$demand->id)->get()->last()->status->name }} {{$demand->closed ? 'Fechada' : 'Aberta'}} VER CHAMADO
{{ $demand->created_at->format('d/m/Y H:i:s')}}
61 anos atras
{{ $demand->type_demand->name }}
{{ $demand->protocol }}
{{$demand->secretariat->name}}
{{ $demand->subject }}
{{ \App\Models\DemandStatusDemand::where('demand_id',$demand->id)->get()->last()->status->name }} {{$demand->closed ? 'Fechada' : 'Aberta'}} VER CHAMADO