@extends('setting.nav') @section('title', 'Import ' . $run->id) @section('content')

Import #{{ $run->id }}

What this run did to the Product Master. Kept so a price that looks wrong can be traced to the file that set it.

Back to products
File
{{ $run->file_name }}
@if ($run->file_url) {{-- Kept so the same sheet can be re-fetched, which is what a scheduled sync will repeat. --}} {{ $run->file_url }} @endif
Source
{{ $run->source === \App\Models\PricingImport::SOURCE_DRIVE ? 'Google Drive' : 'Uploaded file' }}
Status
{{ ucfirst($run->status) }} @if ($run->status === \App\Models\PricingImport::STATUS_RUNNING)
Still marked as running — if this is an old run, it stopped part-way through the file.
@endif
Started
{{ $run->created_at?->format('d M Y H:i') }}
Finished
{{ $run->finished_at?->format('d M Y H:i') ?? '—' }}
@php $tiles = [ ['label' => 'Rows processed', 'value' => $run->total_records, 'class' => 'secondary'], ['label' => 'Products created', 'value' => $run->created_records, 'class' => 'success'], ['label' => 'Products updated', 'value' => $run->updated_records, 'class' => 'primary'], ['label' => 'Prices recorded', 'value' => $run->priced_records, 'class' => 'info'], ['label' => 'Rows rejected', 'value' => $run->failed_records, 'class' => 'danger'], ]; @endphp @foreach ($tiles as $tile)
{{ $tile['label'] }}
{{ number_format($tile['value']) }}
@endforeach
Rejected rows
@if (empty($errors_list))
Nothing was rejected — every row in the file was imported.
@else
Each of these rows was skipped and the rest of the file still imported. Fix them in the spreadsheet and import it again — re-importing rows that already went through changes nothing, because a price that has not moved is not written twice.
{{-- The reasons here are written to be acted on. Anything that needs a stack trace to understand is in the log instead, and this is where to look for it. --}} Rows that failed for a technical reason are recorded in full, with stack traces, in storage/logs/pricing.log.
@foreach ($errors_list as $error) @endforeach
Sheet row Product code Why it was skipped
{{ $error['row'] ?? '—' }} @if (!empty($error['product_code'])) {{ $error['product_code'] }} @else — @endif {{ $error['message'] ?? '' }}
@endif
@endsection