Merge branch 'master' of https://github.com/sebathefox/skolehjem-webapp into master
This commit is contained in:
commit
ab5a6206ce
|
@ -15,9 +15,12 @@
|
||||||
|
|
||||||
<form method="post" action="{{ route("users.store") }}">
|
<form method="post" action="{{ route("users.store") }}">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="text" class="form-controller" id="search" name="search" placeholder="Søg efter navn,email,tlf"></input>
|
<input type="text" class="form-controller" id="search" name="search" placeholder="Søg efter navn,email,tlf"><br>
|
||||||
</form>
|
</form>
|
||||||
|
<button id="filterButton" type="button" class="btn btn-sde-blue">Søg filter</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="showHideCheckbox">
|
||||||
<input class="checkbox-inline" type="checkbox" name="checkbox" id="navn" value="navn">
|
<input class="checkbox-inline" type="checkbox" name="checkbox" id="navn" value="navn">
|
||||||
<label for="navn">Navn</label>
|
<label for="navn">Navn</label>
|
||||||
<input class="checkbox-inline" type="checkbox" name="checkbox" id="efternavn" value="efternavn">
|
<input class="checkbox-inline" type="checkbox" name="checkbox" id="efternavn" value="efternavn">
|
||||||
|
@ -105,6 +108,15 @@
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//Show hide search filter
|
||||||
|
$("#filterButton").click(function(){
|
||||||
|
$('#showHideCheckbox').toggle();
|
||||||
|
});
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -10,6 +10,9 @@
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@section("content")
|
@section("content")
|
||||||
|
<?php
|
||||||
|
date_default_timezone_set('Europe/Copenhagen');
|
||||||
|
?>
|
||||||
<table class="tbl mt-0">
|
<table class="tbl mt-0">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Lokation</th>
|
<th>Lokation</th>
|
||||||
|
@ -19,6 +22,7 @@
|
||||||
<th style="width: 1em;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
<th style="width: 1em;"><img class="w-100" src="{{ asset('/images/icons/trashcan.svg') }}" alt="Delete"></th>
|
||||||
</tr>
|
</tr>
|
||||||
@foreach($reservations as $reservation)
|
@foreach($reservations as $reservation)
|
||||||
|
@if(date('Y-m-d H:i:s', strtotime('-1 hour')) < $reservation->time)
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ \App\Location::query()->find(\App\WashingMachine::query()->find($reservation->machine_id)->location_id)->name }}</td>
|
<td>{{ \App\Location::query()->find(\App\WashingMachine::query()->find($reservation->machine_id)->location_id)->name }}</td>
|
||||||
<td>{{ \App\WashingMachine::query()->find($reservation->machine_id)->name }}</td>
|
<td>{{ \App\WashingMachine::query()->find($reservation->machine_id)->name }}</td>
|
||||||
|
@ -32,6 +36,7 @@
|
||||||
</form>
|
</form>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@endif
|
||||||
@endforeach
|
@endforeach
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
|
|
@ -4,9 +4,14 @@
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@section("content")
|
@section("content")
|
||||||
|
<?php
|
||||||
|
date_default_timezone_set('Europe/Copenhagen');
|
||||||
|
$washingreservations = 0;
|
||||||
|
?>
|
||||||
<main style="min-height: calc(100% - 61.34px);">
|
<main style="min-height: calc(100% - 61.34px);">
|
||||||
<h2 class="text-center sde-blue mb-0">{{__('msg.dinereservationer')}}</h2>
|
<h2 class="text-center sde-blue mb-0">{{__('msg.dinereservationer')}}</h2>
|
||||||
@foreach($reservations as $reservation)
|
@foreach($reservations as $reservation)
|
||||||
|
@if(date('Y-m-d H:i:s', strtotime('-1 hour')) < $reservation->time)
|
||||||
<div class="reservation" style="margin: 0 32px 1.75rem 32px;">
|
<div class="reservation" style="margin: 0 32px 1.75rem 32px;">
|
||||||
<h3>{{ \App\WashingMachine::query()->find($reservation->machine_id)->name }}</h3>
|
<h3>{{ \App\WashingMachine::query()->find($reservation->machine_id)->name }}</h3>
|
||||||
<div class="row align-items-center">
|
<div class="row align-items-center">
|
||||||
|
@ -19,8 +24,12 @@
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<?php
|
||||||
|
$washingreservations++;
|
||||||
|
?>
|
||||||
|
@endif
|
||||||
@endforeach
|
@endforeach
|
||||||
@if(count($reservations) < 1)
|
@if(count($reservations) < 1 || $washingreservations == 0)
|
||||||
<p style="margin: 0 18px;">{{__('msg.duharingenreservationer')}}.</p>
|
<p style="margin: 0 18px;">{{__('msg.duharingenreservationer')}}.</p>
|
||||||
@else
|
@else
|
||||||
{{ $reservations->links() }}
|
{{ $reservations->links() }}
|
||||||
|
|
Loading…
Reference in New Issue