generated from boboko/starter
85 lines
3.9 KiB
PHP
85 lines
3.9 KiB
PHP
{{--
|
|
Order confirmation. Reached only via a session flash of the placed order id
|
|
(CheckoutController::confirmation) — not deep-linkable. $order is a
|
|
Lunar\Models\Order with lines + shipping/billing addresses eager-loaded.
|
|
--}}
|
|
@extends('layouts.app')
|
|
|
|
@section('title', __('checkout.page.confirmation_title') . ' — ' . config('app.name'))
|
|
|
|
@section('content')
|
|
<div class="bbk-confirmation">
|
|
<h1 class="bbk-confirmation-heading">{{ __('checkout.page.confirmation_heading') }}</h1>
|
|
|
|
<p class="bbk-confirmation-ref">
|
|
{{ __('checkout.page.confirmation_order_number') }}: <strong>{{ $order->reference }}</strong>
|
|
</p>
|
|
<p class="bbk-checkout-note">{{ __('checkout.page.confirmation_email_note') }}</p>
|
|
|
|
<div class="bbk-confirmation-body">
|
|
<div class="bbk-confirmation-lines">
|
|
@foreach ($order->lines->where('type', '!=', 'shipping') as $line)
|
|
<div class="bbk-confirmation-line">
|
|
<span class="bbk-confirmation-line-name">
|
|
{{ $line->description }}
|
|
<span class="bbk-confirmation-line-qty">× {{ $line->quantity }}</span>
|
|
</span>
|
|
<span class="bbk-confirmation-line-total">{{ $line->sub_total?->formatted() }}</span>
|
|
</div>
|
|
@endforeach
|
|
|
|
<div class="bbk-cart-summary">
|
|
<div class="bbk-cart-summary-row">
|
|
<span>{{ __('checkout.cart.subtotal') }}</span>
|
|
<span>{{ $order->sub_total?->formatted() }}</span>
|
|
</div>
|
|
|
|
@if ($order->discount_total?->value > 0)
|
|
<div class="bbk-cart-summary-row bbk-cart-summary-row--discount">
|
|
<span>{{ __('checkout.cart.discount') }}</span>
|
|
<span>−{{ $order->discount_total->formatted() }}</span>
|
|
</div>
|
|
@endif
|
|
|
|
<div class="bbk-cart-summary-row">
|
|
<span>{{ __('checkout.cart.shipping') }}</span>
|
|
<span>{{ $order->shipping_total?->formatted() }}</span>
|
|
</div>
|
|
|
|
@if ($order->tax_total?->value > 0)
|
|
<div class="bbk-cart-summary-row">
|
|
<span>{{ __('checkout.cart.tax') }}</span>
|
|
<span>{{ $order->tax_total->formatted() }}</span>
|
|
</div>
|
|
@endif
|
|
|
|
<div class="bbk-cart-summary-row bbk-cart-summary-row--total">
|
|
<span>{{ __('checkout.cart.total') }}</span>
|
|
<span>{{ $order->total?->formatted() }}</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="bbk-confirmation-addresses">
|
|
@if ($order->shippingAddress)
|
|
<div class="bbk-confirmation-address">
|
|
<h2 class="bbk-confirmation-address-heading">{{ __('checkout.page.confirmation_shipping_to') }}</h2>
|
|
<x-checkout::address-lines :address="$order->shippingAddress" />
|
|
</div>
|
|
@endif
|
|
|
|
@if ($order->billingAddress)
|
|
<div class="bbk-confirmation-address">
|
|
<h2 class="bbk-confirmation-address-heading">{{ __('checkout.page.confirmation_billing') }}</h2>
|
|
<x-checkout::address-lines :address="$order->billingAddress" />
|
|
</div>
|
|
@endif
|
|
</div>
|
|
</div>
|
|
|
|
<a class="bbk-checkout-continue bbk-confirmation-continue" href="{{ route('products', app()->getLocale()) }}">
|
|
{{ __('checkout.page.confirmation_continue') }}
|
|
</a>
|
|
</div>
|
|
@endsection
|