@extends('web_site.layouts.master') @php $siteName = $siteData?->name ?? 'BST Clinics'; // Logged-in visitors get their account details pre-filled; the subscription is linked to their account. $account = auth('web')->user(); @endphp @section('content')

{{ trans('site.offers.title') }}

@include('web_site.partials.alerts') @if ($unpaidSubscriptions->isNotEmpty())
{{ trans('site.offers.payment.pending_notice') }}
@foreach ($unpaidSubscriptions as $unpaid)
{{ $unpaid->offerLabel() }} — {{ number_format((float) $unpaid->amount, 2) }} {{ $unpaid->currency }} {{ trans('site.offers.payment.pay_now') }}
@endforeach
@endif @if ($offers->isNotEmpty())
@foreach ($offers as $offer)
@include('web_site.partials.offer-card', ['offer' => $offer, 'index' => $loop->index, 'subscribeInPage' => true])
@endforeach
@endif
{{ $siteName }}

{{ trans('site.offers.app_title', ['name' => $siteName]) }}

{{ trans('site.offers.app_text', ['name' => $siteName]) }}

@csrf

{{ trans('site.offers.form.title') }}

{{ trans('site.offers.form.subtitle') }}

@if ($siteData?->phone)
@endif
@if ($account)

{{ trans('site.offers.form.as_account', ['name' => $account->name]) }}

@endif
@error('name')
{{ $message }}
@enderror
@error('phone')
{{ $message }}
@enderror
@error('address')
{{ $message }}
@enderror
@error('contact_method')
{{ $message }}
@enderror
@error('offer_id')
{{ $message }}
@enderror
@error('message')
{{ $message }}
@enderror
@endsection @section('js') {{-- The offer id is a hidden input, so validate hidden fields too; its error is shown under the read-only offer title. --}} {!! JsValidator::formRequest('App\Http\Requests\Site\StoreOfferSubscriptionRequest', '#offerSubscribeForm')->ignore('') !!} @endsection