{{ __('Message campaigns') }} @if ($flash)
{{ $flash }}
@endif @if ($showForm)
{{ __('New campaign') }}
{{ __('Subscribers matched') }} {{ $this->audienceSize }}
{{ __('SMS credits this will spend') }} {{ $this->creditCost }}
{{ __(':n characters โ€” :p SMS each', [ 'n' => strlen($body), 'p' => max(1, (int) ceil(max(1, strlen($body)) / 160)), ]) }} {{ strlen($body) }} / 480

{{ __('Saving does not send. You send it from the list below, once you have read it back.') }}

@endif
{{ __('Campaigns') }}
@forelse ($this->campaigns as $c) @empty @endforelse
{{ __('Name') }} {{ __('Message') }} {{ __('Audience') }} {{ __('Reached') }} {{ __('Status') }} {{ __('Actions') }}
{{ $c->name }} {{ $c->created_at->format('d M Y, H:i') }} @if ($c->author) ยท {{ $c->author->name }} @endif {{ $c->body }} {{ __(\App\Models\MessageCampaign::AUDIENCES[$c->audience] ?? $c->audience) }} @if ($c->status === 'sent' || $c->status === 'failed') {{ $c->sent_count }} @if ($c->failed_count) {{ __(':n failed', ['n' => $c->failed_count]) }} @endif @else {{ $c->recipients }} @endif @php $tone = match ($c->status) { 'sent' => 'success', 'sending' => 'info', 'failed' => 'danger', default => 'secondary', }; @endphp {{ ucfirst($c->status) }} @if ($c->status === 'draft') @else {{ $c->sent_at?->format('d M, H:i') ?: 'โ€”' }} @endif
{{ __('No campaigns yet.') }}
@if ($this->campaigns->hasPages()) @endif

{{ __('Sends run while the page is open and are capped at 500 numbers per campaign, so a large list finishes rather than timing out half-way.') }}