{{ __('WhatsApp sale notifications') }}

{{ __('Send customer invoices through Flaxxa. Credentials are stored encrypted. A queue worker is required for sending.') }}

@error('whatsapp_token')
{{ $message }}
@enderror
@error('whatsapp_phone')
{{ $message }}
@enderror
@error('whatsapp_message_template')
{{ $message }}
@enderror
{{ __('Placeholders: {customer_name}, {invoice_number}, {invoice_total}, {amount_paid}, {invoice_due}, {date_time}, {shop_name}') }}
@if($canEditSettings)@endif

{{ __('Send a test message') }}
@error('whatsapp_test_recipient')
{{ $message }}
@enderror
@error('whatsapp_test_message')
{{ $message }}
@enderror
@if($canEditSettings)@endif

{{ __('Recent WhatsApp attempts') }}
@forelse($whatsappHistory as $attempt) @empty @endforelse
{{ __('Date') }}{{ __('Invoice') }}{{ __('Status') }}{{ __('Provider result') }}
{{ $attempt->created_at->format('d M Y H:i') }}{{ $attempt->invoice?->invoice_number ?? '—' }}{{ ucfirst($attempt->status) }}{{ $attempt->error ?: ($attempt->http_status ? 'HTTP ' . $attempt->http_status : '—') }}
{{ __('No WhatsApp attempts yet.') }}
@if($whatsappHistory->hasPages())
{{ __('Showing :first to :last of :total attempts', ['first' => $whatsappHistory->firstItem(), 'last' => $whatsappHistory->lastItem(), 'total' => $whatsappHistory->total()]) }}
@endif