@php $ids = collect($rows->items())->pluck('id')->unique()->values()->all(); $inr = fn ($v) => $v === null ? '—' : '₹'.number_format((float) $v, (float) $v == (int) $v ? 0 : 2); $tiles = [ ['all', 'All accounts', 'heroicon-o-banknotes', 'gray'], ['not_allocated', 'Not allocated', 'heroicon-o-inbox', 'gray'], ['NEW DATA', 'New data', 'heroicon-o-sparkles', 'amber'], ['LIVE POSITIVE', 'Live positive', 'heroicon-o-arrow-trending-up', 'green'], ['LIVE NEGATIVE', 'Live negative', 'heroicon-o-arrow-trending-down', 'violet'], ['LOST', 'Lost', 'heroicon-o-x-circle', 'red'], ['PAID', 'Paid', 'heroicon-o-check-badge', 'blue'], ]; @endphp Export ADI users
@foreach ($tiles as [$key, $label, $icon, $tone]) $view === $key])>
{{ $label }}
{{ number_format($counts[$key] ?? 0) }}
@endforeach
@if (($counts['other'] ?? 0) > 0)

{{ number_format($counts['other']) }} assigned account(s) carry a legacy status the app does not list (e.g. “In Progress”). Review them.

@endif
account(s) selected
@csrf @method('DELETE')
@if ($rows->isEmpty()) @else
@foreach ($rows as $r) @endforeach
Make Assigned to
@if ($r->activity_id) {{ \App\Models\AdiActivity::normaliseStatus($r->Status) ?: '—' }} @else Not allocated @endif @if ($r->Allocation_Date)
{{ \Carbon\Carbon::parse($r->Allocation_Date)->format('d-m-Y') }}
@endif
{{ $r->CUSTOMER_NAME ?: '—' }}
{{ $r->CUSTOMER_NO ?: '' }}
{{ $r->LOAN_NO ?: '—' }} @if ($r->Subject)
{{ trim($r->Subject) }}
@endif
{{ $r->TOT_INST_OS ?? '—' }} {{ $r->DPD ?? '—' }} {{ $r->BUCKET ?? '—' }} {{ $inr($r->LOAN_EMI) }} {{ $inr($r->POS) }} {{ $inr($r->TOTAL_AMOUNT_DUE) }} {{ $r->MAKE ?: '—' }}
{{ $r->LOCATION_CITY ?: '—' }}
@if ($r->AREA)
{{ $r->AREA }}
@endif
{{ $r->assigned_user ?: ($r->User_id ? 'User #'.$r->User_id : '—') }}
@endif
@csrf @include('adi.collections._assign-fields')
@csrf

Upload a CSV with a header row. LOAN_NO and CUSTOMER_NAME are required; accounts whose LOAN_NO already exists are skipped. Recognised columns:

@foreach (\App\Models\AdiCollection::IMPORT_COLUMNS as $col){{ $col }}@endforeach
Download sample file