{{-- Fakturor (DESIGN.md Page patterns 2, list page; #2957 slice 6d, card #3020). Shared by the customer route invoice.index and the admin route admin.invoice.index (InvoiceController@index picks the query). The admin route keeps its filter (q, type, status) and the company links; the Ditt konto tabs show on the customer route only, the admin back link and the Kunder tabs on the admin route (slice 12, card #3098). Rows are in partials/list. --}} @extends('layouts.nuhet') @php $isAdminList = Route::currentRouteName() == 'admin.invoice.index'; $filtered = $isAdminList && (request()->filled('q') || request('type', '-1') != '-1' || request('status', '-1') != '-1'); @endphp @section('_pageTitle', __('invoice.index.pageTitle')) @section('pagename', $isAdminList ? __('invoice.invoices') : __('company.nh.paymentTitle')) @section('page') @if ($isAdminList) @include('partials.nh-admin-back') @endif

{{ $isAdminList ? __('invoice.invoices') : __('company.nh.paymentTitle') }}

{{ __('invoice.nh.lead') }}

@if ($isAdminList) @else @include('partials.nh-account-tabs') @if ($canManagePayment ?? false) @include('company.partials.payment-card', ['canManage' => true, 'user' => Auth::user()]) @include('company.partials.payment-card-dialog', ['canManage' => true]) @if ($paymentUnavailable ?? false)

{{ __('company.nh.paymentUnavailable') }}

@endif @endif @endif @if ($isAdminList) @include('invoice.partials.filter') @endif @if ($invoices->isEmpty()) {{ __('invoice.nh.emptyText') }} @if ($filtered) {{ __('invoice.all') }} @endif @else @include('invoice.partials.list', ['invoices' => $invoices, 'isAdminList' => $isAdminList]) @endif @endsection