2020-06-24 07:25:59 +00:00
|
|
|
@extends("app.layout.base")
|
|
|
|
@extends("app.layout.header")
|
2020-06-11 12:52:15 +00:00
|
|
|
@section("title")
|
|
|
|
Menuplan
|
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section("content")
|
2020-06-30 10:38:02 +00:00
|
|
|
<?php
|
|
|
|
$Week = date('W'); //Current week
|
|
|
|
?>
|
|
|
|
<main onload="myFunction()">
|
|
|
|
@if($menuPlans->contains('week', $Week)) {{-- If any of the menues in the menu table has the number of the week in the 'week' column, do this --}}
|
|
|
|
@foreach($menuPlans as $menuplan)
|
|
|
|
@if($menuplan->week == $Week)
|
|
|
|
<h1 class="text-center sde-blue mb-0">Menuplan</h1>
|
|
|
|
<span class="text-center sde-black-80 bold">Uge: {{$menuplan->week}}</span>
|
|
|
|
<div class="col w-100 mt-auto text-center">
|
|
|
|
<div class="w-100" id="mandag">
|
|
|
|
<h3 class="sde-blue bold mb-0">Mandag</h3>
|
|
|
|
<p>{{$menuplan->monday}}</p>
|
|
|
|
</div>
|
|
|
|
<div class="w-100" id="tirsdag">
|
|
|
|
<h3 class="sde-blue bold mb-0">Tirsdag</h3>
|
|
|
|
<p>{{$menuplan->tuesday}}</p>
|
|
|
|
</div>
|
|
|
|
<div class="w-100" id="onsdag">
|
|
|
|
<h3 class="sde-blue bold mb-0">Onsdag</h3>
|
|
|
|
<p>{{$menuplan->wednesday}}</p>
|
|
|
|
</div>
|
|
|
|
<div class="w-100" id="torsdag">
|
|
|
|
<h3 class="sde-blue bold mb-0">Torsdag</h3>
|
|
|
|
<p>{{$menuplan->thursday}}</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@endif
|
|
|
|
@endforeach
|
|
|
|
@else
|
|
|
|
<h1 class="text-center sde-blue mb-0">Menuplan</h1>
|
|
|
|
<p class="text-center">Der er ingen menuplaner denne uge!</p>
|
|
|
|
@endif
|
2020-06-11 12:52:15 +00:00
|
|
|
</main>
|
2020-06-30 10:38:02 +00:00
|
|
|
{{ $menuPlans->links() }}
|
2020-06-11 12:52:15 +00:00
|
|
|
@endsection
|