@php $money = fn ($v) => \App\Services\Insurance\QuotationPresenter::money(is_numeric($v) ? (float) $v : 0); $tabs = ['leads' => ['Contact Us leads', 'heroicon-o-inbox-stack'], 'generated' => ['Assigned quotations', 'heroicon-o-document-duplicate'], 'legacy' => ['Legacy bulk quotations', 'heroicon-o-archive-box']]; @endphp Sample CSV
@foreach ($tabs as $key => [$label, $icon]) $tab === $key, 'text-ink-500 hover:text-ink-800 dark:hover:text-ink-200' => $tab !== $key])> {{ $label }} {{ number_format($counts[$key]) }} @endforeach
@if ($tab === 'leads')
lead(s) selected
@if ($leads->isEmpty()) @else
@foreach ($leads as $lead) @endforeach
Vehicle Reg. date
car)>
{{ $lead->fullname ?: '—' }}
{{ $lead->contact_no }}
{{ $lead->car_reg_no ?: '—' }} @if ($lead->car)
{{ $lead->car->mfg_name }} {{ $lead->car->model }}
{{ $lead->car->sub_model }} · {{ $lead->car->fuel_type }}
@else
{{ trim($lead->mfg_name.' '.$lead->model.' '.$lead->sub_model) ?: '—' }}
Not linked to a vehicle @endif
{{ $lead->car_reg_date ?: '—' }} {{ $lead->ins_expire_date ?: '—' }} {{ $lead->ins_company_name ?: '—' }}
@endif
@csrf

One quotation is created for each of the selected lead(s), priced with the standard premium formula (all add-ons, road-side assistance and 20 % NCB).

Insurer
@foreach (\App\Services\Insurance\PremiumCalculator::INSURERS as $key => $label) @endforeach
@elseif ($tab === 'generated')
@if ($quotations->isEmpty()) @else @include('insurance.quotations._table', ['quotations' => $quotations, 'selectable' => false, 'showCreator' => true]) @endif
@else
@if ($rows->isEmpty()) @else
@foreach ($rows as $row) @endforeach
Vehicle Plan
{{ $row->name ?: '—' }}
{{ $row->mobileno }}
{{ $row->assignee_name ?? ($row->user_id ? 'Former user #'.$row->user_id : '—') }}
{{ trim($row->manufacturer_name.' '.$row->vehicle_model) ?: '—' }}
{{ $row->car?->sub_model }}
{{ $row->selectins_plan ?: 'HDFC' }} {{ $money($row->total_cost) }} {{ $row->created_date?->format('d M Y') }}
@endif
@endif
@csrf

Upload a CSV file (max 2 MB, {{ number_format(\App\Services\Insurance\ContactUsImporter::MAX_ROWS) }} rows) with a header row. Required columns: fullname, contact_no. Optional: car_id, mfg_name, model, sub_model, ins_expire_date, ins_company_name, car_reg_no, car_reg_date (dd/mm/yyyy).

Download the sample file · rows with an invalid mobile number or unknown car id are skipped and reported.