{{-- The notification centre. Everything listed here was raised by something that knows — the scheduled scan over invoices, subscriptions and support SLAs. Nothing on this screen creates one, which is why there is no "new notification" button: news an administrator typed themselves is not news. --}} @php $tones = [ 'rose' => 'bg-rose-50 border-rose-200 text-rose-700', 'amber' => 'bg-amber-50 border-amber-200 text-amber-700', 'orange' => 'bg-orange-50 border-orange-200 text-orange-700', 'sky' => 'bg-sky-50 border-sky-200 text-sky-700', ]; @endphp

Notification centre

{{ $unread > 0 ? $unread.' unread' : 'Nothing unread' }}

Overdue invoices, subscriptions needing attention and breached support SLAs.

@if ($unread > 0)
@csrf
@endif
@if (session('success'))
{{ session('success') }}
@endif
    @forelse ($notifications as $notification) @php $data = $notification->data; $tone = $tones[$data['tone'] ?? 'sky'] ?? $tones['sky']; $isUnread = $notification->read_at === null; @endphp
  • {{ $data['title'] ?? 'Notification' }} @if (! empty($data['brand'])) {{ $data['brand'] }} @endif {{-- Which product said it. Stamped by BCP from the API token, never copied from the request, so it cannot be claimed. --}} @if (! empty($data['source'])) {{ $data['source'] }} @endif {{ $notification->created_at?->diffForHumans() }}

    {{ $data['body'] ?? '' }}

    @if (! empty($data['amount']))

    {{ $data['amount'] }}

    @endif
    @if (! empty($data['url'])) Open @endif @if ($isUnread)
    @csrf
    @endif
  • @empty
  • {{ $unreadOnly ? 'Nothing unread' : 'Nothing to report' }}

    No overdue invoice, no subscription in trouble and no breached SLA. This page fills itself in when there is.

  • @endforelse
@if ($notifications->hasPages())
{{ $notifications->links() }}
@endif