{{ $this->form }} @if (!empty($this->excelData) && empty($this->filteredData) && $this->warehouse)

No data found: No rows match the selected warehouse "{{ $this->warehouse }}". Please check that the Location column in your Excel file matches the warehouse name exactly.

Total rows loaded: {{ count($this->excelData) }}

@if (!empty($this->excelData))
Show first row data (for debugging)
{{ json_encode($this->excelData[0] ?? [], JSON_PRETTY_PRINT) }}
@endif
@endif @if (!empty($this->excelData) && empty($this->filteredData) && empty($this->warehouse))

Data loaded: {{ count($this->excelData) }} row(s) loaded. Please select a warehouse to filter and preview the data.

@endif @php // If warehouse is selected, always use filteredData (even if empty) // Otherwise, show all excelData if (!empty($this->warehouse)) { $previewData = $this->filteredData ?? []; } else { $previewData = $this->excelData ?? []; } @endphp @if (!empty($this->excelData) && !empty($this->warehouse) && empty($this->filteredData))

Debug Info: Warehouse is selected ({{ $this->warehouse }}) but filteredData is empty. Total Excel rows: {{ count($this->excelData) }}. This means no rows match the selected warehouse.

@endif @if (!empty($previewData))

Preview Data ({{ count($previewData) }} rows)

@if ($this->warehouse)

Filtered by: {{ $this->warehouse }}

@else

Showing all data (select warehouse to filter)

@endif
@foreach($previewData as $row) @endforeach
S. Order # D. Note # Customer Rq. Date Booking # Load on Delivered on Truck # Out In Remarks Location Destination Type
{{ $row['s_order'] ?? $row['S. Order # '] ?? $row['s_order_number'] ?? '-' }} {{ $row['d_note'] ?? $row['D. Note #'] ?? $row['d_note_number'] ?? '-' }} {{ $row['customer'] ?? $row['Customer'] ?? '-' }} {{ $row['req_date'] ?? $row['Rq. Date'] ?? $row['rq_date'] ?? '-' }} {{ $row['booking'] ?? $row['Booking #'] ?? $row['booking_number'] ?? '-' }} {{ $row['load_on'] ?? $row['Load on'] ?? '-' }} {{ $row['delivered_on'] ?? $row['Delivered on'] ?? '-' }} {{ $row['truck'] ?? $row['Truck #'] ?? $row['truck_number'] ?? '-' }} {{ $row['out'] ?? $row['Out '] ?? $row['Out'] ?? '-' }} {{ $row['in'] ?? $row['In'] ?? '-' }} {{ $row['remarks'] ?? $row['Remarks'] ?? '-' }} {{ $row['location'] ?? $row['Location'] ?? '-' }} {{ $row['destination'] ?? $row['Destination'] ?? '-' }} {{ $row['type'] ?? $row['Type'] ?? '-' }}
@endif @if (!empty($previewData))
Confirm & Upload ({{ count($previewData) }} rows)
@endif