@extends('layouts.admin') @section('content')

Interesados

@if(request('date_from') || request('date_to'))
Mostrando registros @if(request('date_from')) desde {{ \Carbon\Carbon::parse(request('date_from'))->format('d/m/Y') }} @endif @if(request('date_to')) hasta {{ \Carbon\Carbon::parse(request('date_to'))->format('d/m/Y') }} @endif
@endif
@foreach ($contacts as $contact) @php $cityRelation = $contact->getRelationValue('city'); $cityName = $contact->city ?: ($cityRelation ? $cityRelation->name : ''); @endphp @endforeach
ID Nombre Email Celular Tienda Ciudad Ciudad ID NIT / Cédula Términos Leído Estado Creado Actualizado
{{ $contact->id }} {{ \Illuminate\Support\Str::limit($contact->name, 40) }} {{ \Illuminate\Support\Str::limit($contact->email, 45) }} {{ $contact->phone }} {{ \Illuminate\Support\Str::limit($contact->business_name ?? '-', 40) }} {{ \Illuminate\Support\Str::limit($cityName, 35) }} {{ $contact->city_id ?? '-' }} {{ $contact->nit ?? '-' }} @if($contact->terms_accepted) @else No @endif @if($contact->read) @else No @endif @if($contact->state === 'Existente') {{ $contact->state }} @else {{ $contact->state }} @endif
{{ $contact->created_at->format('d/m/Y') }} {{ $contact->created_at->format('H:i') }}
{{ $contact->updated_at->format('d/m/Y') }} {{ $contact->updated_at->format('H:i') }}
{{ $contacts->links() }} @endsection