v0.5.10 - Added support for menuplan as news creation
This commit is contained in:
@@ -10,6 +10,14 @@
|
||||
@endsection
|
||||
|
||||
@section("content")
|
||||
<style>
|
||||
.toggle__label::before, .toggle__label::after {
|
||||
border-color: black;
|
||||
}
|
||||
.toggle__text::before {
|
||||
border-color: black;
|
||||
}
|
||||
</style>
|
||||
<script src="https://cdn.ckeditor.com/ckeditor5/21.0.0/classic/ckeditor.js"></script>
|
||||
<h1>Opret Menuplan:</h1>
|
||||
<form action="{{ action('MenuPlanController@store') }}" method="post">
|
||||
@@ -17,6 +25,12 @@
|
||||
<label for="week">Uge nr.</label>
|
||||
<input type="number" name="week" id="week" min="1" max="53" placeholder="1" required>
|
||||
<textarea name="menuPlan" id="editor"></textarea>
|
||||
<label class="toggle">
|
||||
<input class="toggle__input" type="checkbox" name="newsoption">
|
||||
<span class="toggle__label">
|
||||
<span class="toggle__text">Opret som nyhed</span>
|
||||
</span>
|
||||
</label>
|
||||
<input type="submit" class="btn btn-dark text-white" value="Opret Menuplan">
|
||||
</form>
|
||||
|
||||
|
||||
@@ -10,6 +10,14 @@
|
||||
@endsection
|
||||
|
||||
@section("content")
|
||||
<style>
|
||||
.toggle__label::before, .toggle__label::after {
|
||||
border-color: black;
|
||||
}
|
||||
.toggle__text::before {
|
||||
border-color: black;
|
||||
}
|
||||
</style>
|
||||
<h1>Rediger Menuplan:</h1>
|
||||
<form method="post" action="{{ route("menu-plans.update", [ "menu_plan" => $menuplan ]) }}">
|
||||
@csrf
|
||||
@@ -24,7 +32,12 @@
|
||||
<input type="text" name="wednesday" id="onsdag" value="{{ $menuplan->wednesday }}" required>
|
||||
<label for="torsdag">Torsdag:</label>
|
||||
<input type="text" name="thursday" id="torsdag" value="{{ $menuplan->thursday }}" required>
|
||||
|
||||
<label class="toggle">
|
||||
<input class="toggle__input" type="checkbox" name="newsoption">
|
||||
<span class="toggle__label">
|
||||
<span class="toggle__text">Opret som nyhed</span>
|
||||
</span>
|
||||
</label>
|
||||
<input type="submit" class="btn btn-dark text-white" value="Rediger Menuplan">
|
||||
</form>
|
||||
@endsection
|
||||
|
||||
@@ -59,8 +59,8 @@
|
||||
|
||||
<main>
|
||||
@foreach(\App\News::query()->orderBy("created_at", "desc")->get() as $new)
|
||||
<div style="border: 4px solid rgba(0,0,0, 0.4); padding: 4px; margin-top: 1rem">
|
||||
<h2 class="sde-blue mt-0 text-center">{{ $new->name }}</h2>
|
||||
<div style="border: 4px solid rgba(0,0,0, 0.2); border-radius: 4px; padding: 4px; margin-top: 1.5rem">
|
||||
<h2 class="sde-blue mt-0 mb-0 text-center" style="margin-bottom: 8px; ">{{ $new->name }}</h2>
|
||||
{!! $new->content !!}
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
Reference in New Issue
Block a user