@extends('adminlte.app') @section('content')
{{ $message }}
{{ $message }}
nr | Postos | Tanque | Produtos | Data Ultima Sondagem | Ultima Sondagem | Quantidade | Dia Entrega Previsto | Data Recebimento | Status | {{--data Agendamento | Data Recebimento | Data Sondagem | --}} @if($permissao->notificar_recebimento_agend_pedido ||$permissao->excluir_agendamentos_pedidos)Ações | @endif
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
{{$agendamento->id_agp}} | @if(isset($agendamento->combustiveis->posto->nome_posto)) {{ $agendamento->combustiveis->posto->nome_posto }} @else @endif | @if(isset($agendamento->num_tanque)) {{$agendamento->num_tanque}} @else @endif | @if(isset($agendamento->combustiveis->produto->descricao)) {{$agendamento->combustiveis->produto->descricao}} @else @endif | @php $ultimaDataSondagem = $agendamento->combustiveis->sondagens_combustiveis()->where('data_sondagem', '<=',$agendamento->created_at)->latest('data_sondagem')->first(); @endphp @if(isset($ultimaDataSondagem->data_sondagem)) {{ \Carbon\Carbon::parse( $ultimaDataSondagem->data_sondagem )->format('d/m/Y') }} @else @endif | @if(isset($ultimaDataSondagem->sondagem_final)) {{ number_format($ultimaDataSondagem->sondagem_final, 0,","," ") }} @else @endif | {{ number_format($agendamento->quantidade, 0,","," ")}} | @if($agendamento->data_agendamento!=''){{date('d/m/Y', strtotime($agendamento->data_agendamento))}}@endif | @if($agendamento->data_recebimento != ''){{date('d/m/Y', strtotime($agendamento->data_recebimento))}}@endif | @if($agendamento->data_recebimento != '') Entregue @elseif(!$agendamento->data_recebimento && $agendamento->data_agendamento < now() ) Atrasado @elseif(!$agendamento->data_recebimento && $agendamento->data_agendamento > now() ) Agendado @endif | @if($permissao->excluir_agendamentos_pedidos||$permissao->notificar_recebimento_agend_pedido)@if($permissao->excluir_agendamentos_pedidos) @endif @if($permissao->notificar_recebimento_agend_pedido) @if($agendamento->data_recebimento == '') @endif @endif | @endif {{-- @if($permissao->notificar_recebimento_agend_pedido) @if($agendamento->data_recebimento == '')@else | @endif @endif --}} |