Ekapp/skolehjem/resources/views/admin/layout/base.blade.php

193 lines
11 KiB
PHP
Raw Normal View History

2020-06-15 06:56:21 +00:00
<!DOCTYPE html>
<html lang="en">
<head>
<title>@yield("title")</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
2020-08-11 07:27:07 +00:00
<script src="{{ asset("/js/jquery-3.2.1.min.js") }}"></script>
<script type="text/javascript">
function openNav() {
fixpls();
var open = document.getElementById("open");
var close = document.getElementById("close");
close.style.display = "block";
open.style.display = "none";
var nav = document.getElementsByClassName("nav")[0];
nav.style.width = "";
var w85 = document.getElementsByClassName("w-85")[0];
$(".w-85").css({ "width": "85%" });
$(".segment > h3").css({"margin-left": "", "width": ""});
$(".segment > h3 > a").css({ "display": ""});
$(".segment > h3 > a > span").css({"display": ""});
$(".segment > div").css({"margin-left": "-1rem", "padding": "1rem 0rem 1rem 2rem", "width": "calc(100% - 3rem)"});
$(".segment > div > a").css({"margin-left": "auto", "margin-right": ""});
localStorage.setItem("collapsed", "false");
}
function closeNav() {
if (localStorage.getItem("collapsed") !== "true")
fixpls();
var open = document.getElementById("open");
var close = document.getElementById("close");
close.style.display = "none";
open.style.display = "block";
var nav = document.getElementsByClassName("nav")[0];
nav.style.width = "64px";
var w85 = document.getElementsByClassName("w-85")[0];
$(".w-85").css({ "width": "calc(100% - 64px)"});
$(".segment > h3").css({"margin-left": "0", "width": "100%"});
$(".segment > h3 > a").css({"display": "flex"});
$(".segment > h3 > a > span").css({"display": "none"});
$(".segment > div").css({"margin-left": "0", "padding": "1rem 0", "width": "100%"});
$(".segment > div > a").css({"margin-left": "auto", "margin-right": "auto"});
localStorage.setItem("collapsed", "true");
}
function checkIfIShouldCollapse() {
if (localStorage.getItem("collapsed") == "true" && document.readyState === "complete") {
closeNav();
fixpls();
}
}
</script>
<link type="text/css" rel="stylesheet" href="{{ mix("/css/admin.css") }}">
</head>
<body>
@yield("header")
<main class="row">
2020-06-15 06:56:21 +00:00
<div class="col nav" style="background-color: #333333;">
2020-08-20 12:56:11 +00:00
<div class="segment" style="height: 60px;">
<div class="text-white row align-items-center" style="margin-left: -1rem; margin-top: 0; margin-bottom: 0; font-size: 1.15rem; height: calc(100% - 2rem); padding: 1rem 2rem; width: calc(100% - 3rem); background-color: #333333 !important;">
<a href="javascript:void(0)" id="open" style="padding: 0; margin-left: auto; display: none;" onclick="openNav()" class="open-btn text-white"><i class="fa fa-bars"></i></a>
<a href="javascript:void(0)" id="close" style="padding: 0; margin-left: auto;" onclick="closeNav()" class="close-btn text-white"><i class="fa fa-times"></i></a>
</div>
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "users.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/users-hvid.svg")}}" class="fa"><span style="margin-left: 4px;">Brugere</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
2020-06-15 06:56:21 +00:00
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route('users.index') }}" class="text-white"><img src="{{asset("/images/icons/users-hvid.svg")}}" class="fa"><span style="margin-left: 4px;">Brugere</span></a></h3>
@endif
2020-06-15 06:56:21 +00:00
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "roles.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/role.svg")}}" class="fa"><span style="margin-left: 4px;">Roller</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
2020-06-30 09:49:17 +00:00
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("roles.index") }}" class="text-white"><img src="{{asset("/images/icons/role.svg")}}" class="fa"><span style="margin-left: 4px;">Roller</span></a></h3>
@endif
2020-06-30 09:49:17 +00:00
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "news.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/news.svg")}}" class="fa"><span style="margin-left: 4px;">Nyheder</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
2020-08-06 10:21:19 +00:00
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("news.index")}}" class="text-white"><img src="{{asset("/images/icons/news.svg")}}" class="fa"><span style="margin-left: 4px;">Nyheder</span></a></h3>
@endif
2020-08-06 10:21:19 +00:00
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "menu-plans.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/Menuplan.svg")}}" class="fa"><span style="margin-left: 4px;">Menuplan</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
2020-06-15 06:56:21 +00:00
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("menu-plans.index")}}" class="text-white"><img src="{{asset("/images/icons/Menuplan.svg")}}" class="fa"><span style="margin-left: 4px;">Menuplan</span></a></h3>
@endif
2020-06-15 06:56:21 +00:00
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "events.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/Aktiviteter.svg")}}" class="fa"><span style="margin-left: 4px;">Aktiviteter</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("events.index") }}" class="text-white"><img src="{{asset("/images/icons/Aktiviteter.svg")}}" class="fa"><span style="margin-left: 4px;">Aktiviteter</span></a></h3>
@endif
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "locations.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/location.svg")}}" class="fa"><span style="margin-left: 4px;">Lokationer</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("locations.index") }}" class="text-white"><img src="{{asset("/images/icons/location.svg")}}" class="fa"><span style="margin-left: 4px;">Lokationer</span></a></h3>
@endif
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "washing-machines.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/wash.svg")}}" class="fa"><span style="margin-left: 4px;">Vaskemaskiner</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("washing-machines.index") }}" class="text-white"><img src="{{asset("/images/icons/wash.svg")}}" class="fa"><span style="margin-left: 4px;">Vaskemaskiner</span></a></h3>
@endif
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "washing-reservations.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/wash_res.svg")}}" class="fa"><span style="margin-left: 4px;">Reservationer</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
2020-06-29 08:14:47 +00:00
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("washing-reservations.index") }}" class="text-white"><img src="{{asset("/images/icons/wash_res.svg")}}" class="fa"><span style="margin-left: 4px;">Reservationer</span></a></h3>
@endif
2020-07-01 07:27:18 +00:00
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "contacts.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/phone.svg")}}" class="fa"><span style="margin-left: 4px;">Kontakter</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
2020-06-30 09:38:28 +00:00
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route("contacts.index") }}" class="text-white"><img src="{{asset("/images/icons/phone.svg")}}" class="fa"><span style="margin-left: 4px;">Kontakter</span></a></h3>
@endif
2020-06-30 09:38:28 +00:00
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "guides.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/Vejledninger.svg")}}" class="fa"><span style="margin-left: 4px;">Vejledning</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route('guides.index') }}" class="text-white"><img src="{{asset("/images/icons/Vejledninger.svg")}}" class="fa"><span style="margin-left: 4px;">Vejledning</span></a></h3>
@endif
</div>
2020-08-20 13:12:06 +00:00
@if(\Illuminate\Support\Facades\Request::route()->getName() == "feedbacks.index")
<div class="segment active">
<h3 class="text-white"><a href="#" class="text-white"><img src="{{asset("/images/icons/feedback.svg")}}" class="fa"><span style="margin-left: 4px;">Feedback</span></a></h3>
2020-08-20 13:12:06 +00:00
@else
<div class="segment">
2020-08-20 12:56:11 +00:00
<h3 class="text-white"><a href="{{ route('feedbacks.index') }}" class="text-white"><img src="{{asset("/images/icons/feedback.svg")}}" class="fa"><span style="margin-left: 4px;">Feedback</span></a></h3>
@endif
2020-06-29 08:14:47 +00:00
</div>
2020-06-15 06:56:21 +00:00
</div>
<div class="w-85" style="background-color: #cccccc;">
2020-06-15 06:56:21 +00:00
<div class="directorypath text-white">
2020-06-17 09:28:48 +00:00
<a href="{{ route('root.index') }}" class="text-white">Home</a> / @yield("path")
2020-06-15 06:56:21 +00:00
</div>
<div class="content">
@yield("content")
</div>
</div>
<script>
if(localStorage.getItem("collapsed") == "true")
closeNav();
</script>
2020-06-15 06:56:21 +00:00
</main>
<script src="{{ mix("/js/app.js") }}"></script>
2020-08-11 08:38:49 +00:00
<script src="{{ asset("/js/jquery.are-you-sure.js") }}"></script>
<script>
function fixpls() {
document.getElementsByClassName("nav")[0].style.transition = "width .5s";
document.getElementsByClassName("w-85")[0].style.transition = "width .5s";
}
2020-08-20 12:56:11 +00:00
</script>
2020-06-15 06:56:21 +00:00
@yield("scripts")
</body>
</html>