Pivot scaffolding and new views for adding beers

This commit is contained in:
2021-09-05 02:09:38 +02:00
parent 26dbfeb94a
commit f4c030934a
11 changed files with 124 additions and 13 deletions

View File

@@ -2,5 +2,32 @@
@section('content')
{{ $list->title }}
<form method="POST" action="{{ route('list.additem', $list->id) }}">
@csrf
<select name="beer">
<option hidden>
-Add Beer-
</option>
@foreach ($beers as $beer)
<option value="{{ $beer->id }}">
<div class="w-20">
<p>
{{ $beer->beer }}
</p>
<br>
<p>
Rating: {{ $beer->rating }}
</p>
</div>
</option>
@endforeach
</select>
<button type="submit">
Add beer
</button>
</form>
<a href="{{ route('beer.create') }}">
Can't find your beer?
</a>
@endsection