- Implement OfferOptionAdminTest to validate offer option management, including price display, activation, and cancellation. - Create OrganizationPurchaseTest to ensure correct handling of organization purchases, including access control and order processing. - Add ShopProductPageTest to verify shop product listings, search functionality, and product page details. - Introduce BuildsShop trait for seeding test data related to shop functionality. - Implement MoneyTest to validate money parsing and formatting, ensuring correct handling of euro amounts.
36 lines
1.7 KiB
PHP
36 lines
1.7 KiB
PHP
@extends('layouts.site')
|
|
|
|
@section('title', 'Shop')
|
|
|
|
@section('content')
|
|
<h1>Shop</h1>
|
|
<p class="lede">Hier findest du kaufbare Programme. Jede Kachel öffnet die Produktseite mit Inhalt und den verfügbaren Lizenzoptionen.</p>
|
|
|
|
<form class="shop-search" method="get" action="{{ route('shop') }}" role="search">
|
|
<label for="shop-suche">Shop durchsuchen</label>
|
|
<input id="shop-suche" type="search" name="suche" value="{{ $term }}" autocomplete="off">
|
|
<button class="button" type="submit">Suchen</button>
|
|
@if ($term !== '')
|
|
<a class="button button-quiet" href="{{ route('shop') }}">Suche zurücksetzen</a>
|
|
@endif
|
|
</form>
|
|
|
|
@if ($cards === [])
|
|
<div class="empty">
|
|
<h2>{{ $term !== '' ? 'Keine Treffer' : 'Noch keine kaufbaren Produkte' }}</h2>
|
|
<p>{{ $term !== '' ? 'Zu „'.$term.'“ gibt es keine kaufbaren Produkte. Prüfe die Schreibweise oder setze die Suche zurück.' : 'Sobald ein Angebot aktiv ist, erscheint es hier.' }}</p>
|
|
</div>
|
|
@else
|
|
<p class="shop-count" role="status">{{ count($cards) }} {{ count($cards) === 1 ? 'Produkt' : 'Produkte' }}</p>
|
|
<ul class="shop-tiles">
|
|
@foreach ($cards as $card)
|
|
<li class="shop-tile">
|
|
<h2><a href="{{ route('public.program', $card['composition']) }}">{{ $card['title'] }}</a></h2>
|
|
@if ($card['teaser'] !== '')<p>{{ $card['teaser'] }}</p>@endif
|
|
<p class="shop-tile-price">ab {{ $card['from'] }} · {{ $card['count'] }} {{ $card['count'] === 1 ? 'Lizenzoption' : 'Lizenzoptionen' }}</p>
|
|
</li>
|
|
@endforeach
|
|
</ul>
|
|
@endif
|
|
@endsection
|