@extends('layouts.dashboard') @section('content') @php /** * Vendor → Menu → Archive: what past imports did to this menu, and when. * * The counts were recorded on every apply and shown nowhere — an import disappeared from the * interface the moment it succeeded. "Twelve dishes came in wrong; which import was that?" had * no answer but memory. * * Deliberately read-only. Bulk import is irreversible here, as it is across this market, and the * review step is what stands between a file and the menu. This is the history, not an undo. * * @var array $imports applied imports, newest first * @var array $pager paginate() result */ $imports = $imports ?? []; @endphp @php /* .qm-d2: the dashboard density standard (app.css §35) */ @endphp

{{ t_raw('vendor.menu.archive_title') }}

@if ($imports) @foreach ($imports as $im) @php /* Added and updated carry colour because they are what CHANGED; skipped stays neutral — a skipped row is the import behaving, not a problem. */ @endphp @endforeach @else @partial('table-empty', ['colspan' => 7, 'icon' => 'fa-history', 'msg' => t_raw('vendor.menu.archive_empty')]) @endif
{{ t_raw('vendor.menu.draft_col_name') }} {{ t_raw('vendor.menu.draft_col_source') }} {{ t_raw('vendor.menu.import_stat_found') }} {{ t_raw('vendor.menu.archive_col_added') }} {{ t_raw('vendor.menu.archive_col_updated') }} {{ t_raw('vendor.menu.archive_col_skipped') }} {{ t_raw('common.date') }}
{{ (string) $im['name'] }} {{ \App\Services\MenuImportMethod::label(\App\Services\MenuImportMethod::ofInput((string) $im['source'])) }} {{ number_format((int) $im['dish_count']) }}{{ number_format((int) $im['added_count']) }} {{ number_format((int) $im['updated_count']) }} {{ number_format((int) $im['skipped_count']) }} {!! $im['applied_at'] ? fmt_datetime((string) $im['applied_at']) : '—' !!}
@if ($imports) @partial('table-toolbar', ['pager' => $pager, 'base' => '/vendor/menu/archive']) @endif
@php /* /.qm-d2 */ @endphp @endsection