@extends('layouts.admin') @section('title', __('Pages')) @section('mobile_title', __('Pages')) @section('content')

{{ __('Pre-registration pages') }}

{{ __('Manage landing pages and subscriber lists.') }}

@can('create', \App\Models\PreregistrationPage::class) {{ __('New page') }} @endcan
@if (auth()->user()->isSuperadmin()) @endif @forelse ($pages as $page) @php $publicUrl = route('public.page', ['publicPage' => $page]); $key = $page->statusKey(); $statusClasses = match ($key) { 'before_start' => 'bg-slate-100 text-slate-800', 'active' => 'bg-emerald-100 text-emerald-800', 'expired' => 'bg-rose-100 text-rose-800', default => 'bg-slate-100 text-slate-800', }; $statusLabel = match ($key) { 'before_start' => __('Before start'), 'active' => __('Active'), 'expired' => __('Expired'), default => $key, }; @endphp @if (auth()->user()->isSuperadmin()) @endif @empty @endforelse
{{ __('Owner') }}{{ __('Title') }} {{ __('Status') }} {{ __('Start') }} {{ __('End') }} {{ __('Subscribers') }} {{ __('Actions') }}
{{ $page->user?->email ?? '—' }}{{ $page->title }} {{ $statusLabel }} {{ $page->start_date->timezone(config('app.timezone'))->format('Y-m-d H:i') }} {{ $page->end_date->timezone(config('app.timezone'))->format('Y-m-d H:i') }} {{ number_format($page->subscribers_count) }}
@can('update', $page) {{ __('Edit') }} @endcan @can('view', $page) {{ __('Subscribers') }} @endcan @can('update', $page) {{ __('Mailwizz') }} @endcan @can('delete', $page)
@csrf @method('DELETE')
@endcan
{{ __('No pages yet.') }} @can('create', \App\Models\PreregistrationPage::class) {{ __('Create one') }} @endcan
@endsection