Fixed css and created the washing reservation index for app

This commit is contained in:
frederikpyt 2020-07-30 10:11:52 +02:00
parent 4a1002edf3
commit 06346d9675
8 changed files with 38 additions and 37 deletions

View File

@ -6592,7 +6592,6 @@ main {
margin-left: -1rem;
margin-top: 0;
width: calc(100% + 1rem);
text-align: center;
margin-bottom: 0;
font-size: 1.15em;
}

View File

@ -6618,6 +6618,10 @@ main {
font-size: 12vw;
}
h2 {
font-size: 10vw;
}
h3 {
font-size: 8vw;
}

View File

@ -8,7 +8,6 @@
margin-left: -1rem;
margin-top: 0;
width: calc(100% + 1rem);
text-align: center;
margin-bottom: 0;
font-size: 1.15em;
}

View File

@ -51,6 +51,10 @@ and (max-width : 900px)
font-size: 12vw;
}
h2 {
font-size: 10vw;
}
h3 {
font-size: 8vw;
}

View File

@ -12,31 +12,31 @@
<main class="row">
<div class="col nav" style="background-color: #333333;">
<div class="segment">
<h3 class="text-white"><a href="{{ route('users.index') }}" class="text-white">Brugere</a></h3>
<h3 class="text-white"><a href="{{ route('users.index') }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Brugere</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route("roles.index") }}" class="text-white">Roller</a></h3>
<h3 class="text-white"><a href="{{ route("roles.index") }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Roller</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route("menu-plans.index")}}" class="text-white">Menuplan</a></h3>
<h3 class="text-white"><a href="{{ route("menu-plans.index")}}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Menuplan</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route("events.index") }}" class="text-white">Aktiviteter</a></h3>
<h3 class="text-white"><a href="{{ route("events.index") }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Aktiviteter</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route("washing-machines.index") }}" class="text-white">Vaskemaskiner</a></h3>
<h3 class="text-white"><a href="{{ route("washing-machines.index") }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Vaskemaskiner</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route("washing-reservations.index") }}" class="text-white">Vaskemaskiner Reservationer</a></h3>
<h3 class="text-white"><a href="{{ route("washing-reservations.index") }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Reservationer</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route("external-links.index") }}" class="text-white">Eksterne Links</a></h3>
<h3 class="text-white"><a href="{{ route("external-links.index") }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Eksterne Links</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route("contacts.index") }}" class="text-white">Kontakter</a></h3>
<h3 class="text-white"><a href="{{ route("contacts.index") }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Kontakter</span></a></h3>
</div>
<div class="segment">
<h3 class="text-white"><a href="{{ route('feedbacks.index') }}" class="text-white">Feedback</a></h3>
<h3 class="text-white"><a href="{{ route('feedbacks.index') }}" class="text-white"><i class="fa fa-link"></i><span style="margin-left: 4px;">Feedback</span></a></h3>
</div>
</div>
<div class="w-85" style="background-color: #cccccc;">

View File

@ -26,7 +26,7 @@
<img src="{{URL::asset('/images/icons/Aktiviteter.svg')}}" alt="Aktiviteter">
Aktiviteter
</a>
<a href="{{ route("washing-reservations.create") }}">
<a href="{{ route("washing-reservations.index") }}">
<img src="{{URL::asset('/images/icons/Vaske booking liste.svg')}}" alt="Reservationer">
Reservationer
</a>

View File

@ -27,9 +27,6 @@
</div>
<form method="post" action="{{ route("washing-reservations.store") }}" id="event-container" class="events-container">
@csrf
<p>
Maskiner skal dynamisk opdateres alt efter om det er en fra bygning E eller en af de andre bygninger der vil vaske, da bygning E har egen vaskekælder!
</p>
</form>
</div>
</main>
@ -46,7 +43,7 @@
return moment(index, "e").locale("da").startOf("week").weekday(index).format("ddd");
});
document.getElementById("title").innerText = moment().locale("da").day(weekDays[0]).week(week).isoWeek().toString();
document.getElementById("title").innerHTML = 'Uge ' + moment().locale("da").day(weekDays[0]).week(week).isoWeek().toString();
const calendar = document.getElementById("calendar");

View File

@ -1,31 +1,29 @@
@extends("app.layout.base")
@section("title")
Booking Liste
Reservationer
@endsection
@section("content")
<main>
<h1 class="text-center sde-blue mb-0">Booking Liste</h1>
<div class="col w-100 mt-auto">
<div class="calendar-container">
<div class="calendar-container__header">
<button id="week-previous" class="calendar-container__btn fas fa-arrow-left" title="Previous">
<i class="icon ion-ios-arrow-back"></i>
</button>
<h2 id="title" class="calendar-container__title">{Måned} {År}</h2>
<button id="week-next" class="calendar-container__btn fas fa-arrow-right" title="Next">
<i class="icon ion-ios-arrow-forward"></i>
</button>
</div>
<div class="calendar-container__body">
<div id="calendar" class="calendar-table">
<div class="calendar-table__body">
<main style="min-height: calc(100% - 61.34px);">
<h2 class="text-center sde-blue mb-0">Dine reservationer</h2>
@foreach($reservations as $reservation)
<div class="reservation" style="margin: 0 32px;">
<h3>{{ \App\WashingMachine::query()->find($reservation->machine_id)->name }}</h3>
<div class="row align-items-center">
<span style="font-size: 4vw"><b>Tid:</b> {{ \Illuminate\Support\Facades\Date::createFromTimeStamp(strtotime($reservation->time))->format('d/m/Y \k\l\. H:i') }}</span>
<form class="ml-auto" method="post" action="{{ route("washing-reservations.destroy", [ "washing_reservation" => $reservation ]) }}">
@csrf
@method("delete")
<input type="hidden" name="id" value="{{ $reservation->id }}">
<button class="btn btn-sde-blue mb-0" type="submit" onclick="return confirm('Are you sure you want to remove this reservation?');">Fjern</button>
</form>
</div>
</div>
</div>
</div>
<div></div>
</div>
@endforeach
@if(count($reservations) < 1)
<p style="margin: 0 18px;">Du har ingen reservationer.</p>
@endif
<a href="{{ route("washing-reservations.create") }}" class="btn btn-sde-blue mt-auto mb-1">Reserver vaskemaskine</a>
</main>
@endsection