feat: CTA dos cards e faixa de modalidades enviam ao WhatsApp com mensagem por pacote
Campo whatsapp_message editável por modalidade (Filament) com fallback para template padrão. Cards da home, faixa 'Conversar com a Amare' e CTA final da página de detalhe abrem o WhatsApp diretamente quando número configurado, mantendo briefing como fallback.
This commit is contained in:
@@ -15,7 +15,9 @@
|
||||
])
|
||||
|
||||
@php
|
||||
$bandHref = $bandCtaHref ?? route('briefing');
|
||||
$bandLink = $bandCtaHref
|
||||
? ['href' => $bandCtaHref, 'isWhatsapp' => false]
|
||||
: \App\Support\PackageContactLink::generic($settings);
|
||||
@endphp
|
||||
<section
|
||||
aria-labelledby="packages-heading"
|
||||
@@ -52,7 +54,7 @@
|
||||
</ul>
|
||||
</div>
|
||||
<div class="space-y-5">
|
||||
@php($contactLink = $ctaRoute ? null : \App\Support\PackageContactLink::for($settings, $package->name))
|
||||
@php($contactLink = $ctaRoute ? null : \App\Support\PackageContactLink::for($settings, $package->name, $package->whatsapp_message))
|
||||
<a
|
||||
href="{{ $ctaRoute ? route($ctaRoute) : $contactLink['href'] }}"
|
||||
@if ($ctaRoute === null && $contactLink['isWhatsapp']) target="_blank" rel="noopener noreferrer" @endif
|
||||
@@ -77,7 +79,11 @@
|
||||
<h3 class="text-[clamp(1.5625rem,2.7vw,2.125rem)] font-medium leading-tight">Ainda não sabe qual modalidade é ideal?</h3>
|
||||
<p class="text-amare-accent-text/80">{{ $bandBody }}</p>
|
||||
</div>
|
||||
<a href="{{ $bandHref }}" class="inline-flex min-h-[48px] items-center justify-center self-start border border-amare-accent-text px-6 text-xs font-bold uppercase tracking-[0.09em] text-amare-accent-text transition-colors hover:bg-amare-accent-text hover:text-amare-accent-deep md:self-auto">
|
||||
<a
|
||||
href="{{ $bandLink['href'] }}"
|
||||
@if ($bandLink['isWhatsapp']) target="_blank" rel="noopener noreferrer" @endif
|
||||
class="inline-flex min-h-[48px] items-center justify-center self-start border border-amare-accent-text px-6 text-xs font-bold uppercase tracking-[0.09em] text-amare-accent-text transition-colors hover:bg-amare-accent-text hover:text-amare-accent-deep md:self-auto"
|
||||
>
|
||||
Conversar com a Amare
|
||||
</a>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user