New Promotion
New Promotion
Override service prices for a set period
← Back
@csrf
@error('name')

{{ $message }}

@enderror
@error('starts_at')

{{ $message }}

@enderror
@error('ends_at')

{{ $message }}

@enderror

Services & Promo Prices

Tick a service to include it. Services with vehicle-type variations let you set a promo price per variation. Services without variations use a single promo price.

@foreach($services as $i => $svc) @php $hasVariations = $svc->variations->isNotEmpty(); $oldSvcs = collect(old('services', [])); $oldEntry = $oldSvcs->firstWhere('id', $svc->id); $checked = $oldEntry !== null; @endphp
{{-- Service header row --}}
@if(!$hasVariations) {{-- Single price input for services without variations --}} Normal: KSh {{ number_format($svc->price, 2) }} @else {{ $svc->variations->count() }} variations ▾ @endif
{{-- Variations sub-table (only for services with variations) --}} @if($hasVariations)
@foreach($svc->variations as $vi => $var) @php $oldVars = collect($oldEntry['variations'] ?? []); $oldVarEntry= $oldVars->firstWhere('id', $var->id); @endphp @endforeach
Vehicle Type Normal Price Promo Price
{{ $var->vehicle_type }} KSh {{ number_format($var->price, 2) }}
@endif
@endforeach
@push('scripts') @endpush