@extends('layouts.app', [ 'navClass' => 'navbar-light bg-secondary', 'parentSection' => 'laravel', 'elementName' => 'client-management' ]) @section('title', 'Clientes |') @section('content') @component('layouts.headers.auth') @component('layouts.headers.breadcrumbs') @slot('title') Clientes @endslot @endcomponent @endcomponent

Lista de Clientes

Abaixo você encontra os clientes cadastrados no TravelTogether

@include('alerts.success') @include('alerts.errors')
@foreach ($clients as $client) @php $now = new DateTime(); @endphp @endforeach
Nome Email Telefone CPF/CNPJ Idade Nascimento Tipo Assinatura Passageiros Vinculados Ações
{{ substr($client->first_name ." ". $client->last_name, 0, 30) }} {{ $client->email }} {{ $client->phone_number }} @if ( empty($client->cpf) ) {{$client->cnpj}} @else {{$client->cpf}} @endif {{ $now->diff(new DateTime( $client->birth_date ))->y }} {{ date('d/m/Y', strtotime($client->birth_date)) }} @if ($client->kind == "PF") PF @else PJ @endif @if ($signatures->where('client_id', '=', $client->id)->count() > 0 ) Ver @else Tornar Exclusivo @endif {{ $passengers->where('client_id', '=', $client->id)->count() }} Ver
@include('layouts.footers.auth')
@endsection @push('css') @endpush @push('js') @endpush