Files
WitShop/resources/views/shop/checkout/confirm.blade.php
T
marcoandClaude Sonnet 4.6 092dae6085
Deploy to Production (witstore.wende.it) / deploy (push) Successful in 8s
Add coupons, newsletter, country-based shipping, sale prices, USP bar
- Gutscheincodes: DB-Verwaltung (%, €-Rabatt, Mindestbestellwert, Ablauf),
  Eingabefeld im Checkout, Admin unter Marketing → Gutscheine
- Newsletter: Double-Opt-In per E-Mail, Formular im Footer,
  Admin-Liste mit CSV-Export
- Länderzonen-Versand: DE / DACH / EU / WORLD, Versandkosten nach
  Lieferland dynamisch berechnet, Coupon-Rabatt in Bestellung gespeichert
- Sale-Preise: sale_price auf Produkten, durchgestrichener UVP auf
  Produktkarte, Sonderangebote-Sektion auf Startseite
- USP-Leiste auf Startseite: Versand, Zahlung, Rückgabe, Service

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-21 11:07:14 +02:00

66 lines
3.4 KiB
PHP

@extends('layouts.shop')
@section('title', 'Bestellung bestätigen')
@section('content')
<h1 class="text-2xl font-bold mb-6">Bestellung prüfen und absenden</h1>
<div class="grid grid-cols-1 md:grid-cols-3 gap-8">
<div class="md:col-span-2 space-y-6">
<div class="bg-white border rounded-lg p-6">
<h2 class="font-semibold mb-3">Lieferadresse</h2>
@php $addr = $checkoutData['shipping'] ?? $checkoutData['billing']; @endphp
<p class="text-sm">{{ $addr['first_name'] }} {{ $addr['last_name'] }}<br>{{ $addr['street'] }}<br>{{ $addr['zip'] }} {{ $addr['city'] }}</p>
</div>
<div class="bg-white border rounded-lg p-6">
<h2 class="font-semibold mb-3">Bestellpositionen</h2>
<table class="w-full text-sm">
<thead class="bg-gray-50"><tr><th class="px-3 py-2 text-left">Artikel</th><th class="px-3 py-2 text-center">Menge</th><th class="px-3 py-2 text-right">Gesamt</th></tr></thead>
<tbody class="divide-y">
@foreach($items as $item)
<tr>
<td class="px-3 py-2">{{ $item['product_name'] }}@if($item['variant_label']) <span class="text-gray-400">({{ $item['variant_label'] }})</span>@endif</td>
<td class="px-3 py-2 text-center">{{ $item['qty'] }}</td>
<td class="px-3 py-2 text-right">{{ number_format($item['price'] * $item['qty'], 2, ',', '.') }} €</td>
</tr>
@endforeach
</tbody>
</table>
</div>
<div class="bg-white border rounded-lg p-6">
<h2 class="font-semibold mb-2">Zahlungsart</h2>
<p class="text-sm">{{ \App\Models\Order::$paymentLabels[$checkoutData['payment_method']] }}</p>
</div>
<form method="POST" action="{{ route('checkout.confirm') }}">
@csrf
<button class="w-full bg-green-600 text-white py-4 rounded-lg hover:bg-green-700 font-bold text-lg">
🛒 Jetzt kostenpflichtig bestellen
</button>
</form>
<p class="text-xs text-gray-400 text-center">
Mit der Bestellung akzeptieren Sie unsere <a href="{{ route('page', 'agb') }}" class="underline">AGB</a> und die <a href="{{ route('page', 'widerrufsbelehrung') }}" class="underline">Widerrufsbelehrung</a>.
</p>
</div>
<div>
<div class="bg-white border rounded-lg p-6 sticky top-4">
<div class="space-y-2 text-sm mb-3 border-b pb-3">
<div class="flex justify-between"><span>Zwischensumme</span><span>{{ number_format($subtotal, 2, ',', '.') }} €</span></div>
@if(($discount ?? 0) > 0)
<div class="flex justify-between text-green-600">
<span>Gutschein ({{ $couponCode }})</span><span>- {{ number_format($discount, 2, ',', '.') }} €</span>
</div>
@endif
<div class="flex justify-between"><span>Versand</span><span>{{ $shippingCost == 0 ? 'Kostenlos' : number_format($shippingCost, 2, ',', '.') . ' €' }}</span></div>
</div>
<div class="flex justify-between font-bold text-lg">
<span>Gesamt</span><span>{{ number_format($total, 2, ',', '.') }} €</span>
</div>
<p class="text-xs text-gray-400 mt-1">inkl. MwSt.</p>
</div>
</div>
</div>
@endsection