Öffne Katalog, Bibliothek und Testkauf für den MVP.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
463851d402
commit
fd6860efda
51 files changed
+2331
-31
No files matched your search
@@ -0,0 +1,36 @@
|
||||
@extends('layouts.site')
|
||||
|
||||
@section('title', 'Angebote')
|
||||
|
||||
@section('content')
|
||||
@include('member.partials.nav')
|
||||
<h1>Angebote</h1>
|
||||
@if ($errors->any())
|
||||
<div class="errors" role="alert">{{ $errors->first() }}</div>
|
||||
@endif
|
||||
@if ($offers->isEmpty())
|
||||
<div class="empty"><p>Gerade ist kein persönliches Angebot aktiv.</p></div>
|
||||
@else
|
||||
<ul class="catalog">
|
||||
@foreach ($offers as $offer)
|
||||
@php $version = $offer->versions->first(); @endphp
|
||||
<li>
|
||||
<strong>{{ $offer->name }}</strong>
|
||||
@if ($version)
|
||||
<span>
|
||||
@if ($version->grant_kind === 'kauf')
|
||||
{{ number_format($version->price_cents / 100, 2, ',', '.') }} € · Testzahlung
|
||||
@else
|
||||
Kostenlos
|
||||
@endif
|
||||
</span>
|
||||
<form method="post" action="{{ $version->grant_kind === 'kauf' ? route('member.offers.buy', $offer) : route('member.offers.claim', $offer) }}">
|
||||
@csrf
|
||||
<button class="button" type="submit">{{ $version->grant_kind === 'kauf' ? 'Kaufen' : 'In die Bibliothek' }}</button>
|
||||
</form>
|
||||
@endif
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
@endif
|
||||
@endsection
|
||||
Reference in new issue
Block a user