COMPARECER AO BALCÃO
@php
// Obtém todos os atendimentos com o status "finalizado"
$atendimentosFinalizados = $queryatendimento->where('status', 'finalizado');
if ($atendimentosFinalizados->isNotEmpty()) {
// Encontra o atendimento com o maior ID
$atendimento = $atendimentosFinalizados->sortByDesc('id')->first();
} else {
$atendimento = null;
}
@endphp
@if ($atendimento)
{{ $atendimento->table_join_id }}
{{ $atendimento->nome }}
{{ $atendimento->empresa }}
@else
-
Não há senhas para exibir.
-
@endif
{{-- Proximas Senhas --}}
PŔOXIMAS SENHAS
|
Senha
|
Empresa
|
Nome
|
Status
|
@foreach ($queryatendimento as $atendimento)
@if ($atendimento->status == 'pendente')
|
{{$atendimento->table_join_id}}
|
{{ucfirst($atendimento->empresa)}}
|
{{ucfirst($atendimento->nome)}}
|
@if ($atendimento->status == 'pendente')
{{ ucfirst($atendimento->status) }}
@else
{{ $atendimento->status }}
@endif
|
@else
@endif
@endforeach