{{-- The processing agreement, in the console. Upload left, what is in force and who has it right, the versions underneath. Uploading and publishing are two acts on purpose: publishing leaves every customer outstanding again, and that is not something to trigger by dropping a file on a form. --}}

{{ __('dpa_admin.eyebrow') }}

{{ __('dpa_admin.title') }}

{{ __('dpa_admin.subtitle') }}

{{-- ── Upload ─────────────────────────────────────────────────────── --}}

{{ __('dpa_admin.upload_title') }}

{{ __('dpa_admin.upload_sub') }}

@error('agreement')

{{ $message }}

@enderror
@error('measures')

{{ $message }}

@enderror
{{ __('dpa_admin.upload_cta') }}
{{-- ── What is in force ───────────────────────────────────────────── --}}

{{ __('dpa_admin.current_title') }}

@if ($current === null)

{{ __('dpa_admin.none_yet') }}

@else

{{ $current->version }}

{{-- R19: stored in UTC, read on the wall clock. --}}

{{ __('dpa_admin.in_force_since', ['when' => $current->published_at->local()->isoFormat('LL')]) }}

{{ __('dpa_admin.accepted_count', ['accepted' => $accepted, 'total' => $customers]) }}

@if ($outstanding > 0)

{{ __('dpa_admin.outstanding', ['count' => $outstanding]) }}

@endif
@endif
{{-- ── The versions ───────────────────────────────────────────────────── --}}

{{ __('dpa_admin.versions_title') }}

@if ($versions->isEmpty())

{{ __('dpa_admin.no_versions') }}

@else
@foreach ($versions as $v) @endforeach
{{ __('dpa_admin.col_version') }} {{ __('dpa_admin.col_state') }} {{ __('dpa_admin.col_accepted') }} {{ __('dpa_admin.col_files') }}
{{ $v->version }} @if ($v->note) {{ $v->note }} @endif @if ($v->isPublished()) {{ $current?->id === $v->id ? __('dpa_admin.state_current') : __('dpa_admin.state_superseded') }} {{ $v->published_at->local()->isoFormat('LL') }} @else {{ __('dpa_admin.state_draft') }} @endif {{ $v->acceptances_count }} @if (! $v->isPublished()) {{-- R23: a modal, because publishing leaves every customer outstanding again. --}} {{ __('dpa_admin.publish') }} @endif
@endif