Files
librenms-librenms/resources/views/layouts/install.blade.php

133 lines
4.5 KiB
PHP
Raw Normal View History

2020-06-05 14:26:57 -05:00
<!DOCTYPE HTML>
<html lang="en">
<head>
<title>@lang('install.title')</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
2020-06-07 10:36:45 -05:00
<link href="{{ asset('css/bootstrap4.min.css') }}" rel="stylesheet" type="text/css"/>
<link href="{{ asset(\LibreNMS\Config::get('stylesheet')) }}" rel="stylesheet" type="text/css"/>
<link href="{{ asset('css/font-awesome.min.css') }}" rel="stylesheet" type="text/css"/>
2020-06-05 14:26:57 -05:00
<script src="{{ asset('js/jquery.min.js') }}"></script>
2020-06-07 10:36:45 -05:00
<script src="{{ asset('js/bootstrap4.min.js') }}"></script>
2020-06-06 17:26:25 -05:00
<style type="text/css">
2020-06-13 15:41:11 -05:00
body {
background-color: #046C8B;
2020-06-06 17:26:25 -05:00
}
2020-06-13 15:41:11 -05:00
.primary-panel {
padding: 0;
border:0;
2020-06-13 16:15:53 -05:00
box-shadow: 3px 3px 30px #222;
2020-06-13 15:41:11 -05:00
min-height: 540px;
2020-06-07 00:03:57 -05:00
}
2020-06-06 17:26:25 -05:00
.btn-circle {
2020-06-07 00:03:57 -05:00
width: 60px;
height: 60px;
padding: 8px 14px;
border-radius: 30px;
2020-06-06 17:26:25 -05:00
font-size: 24px;
2020-06-07 00:03:57 -05:00
line-height: 1.7;
box-shadow: 2px 2px 4px grey;
2020-06-06 17:26:25 -05:00
}
2020-06-13 15:41:11 -05:00
.card-img-top {
2020-06-13 16:15:53 -05:00
background-color: #EEEEEE;
2020-06-13 15:41:11 -05:00
}
2020-06-13 09:35:28 -05:00
#progress-icons {
2020-06-13 16:15:53 -05:00
background: linear-gradient(to bottom, #EEEEEE 50%, white 50%)
2020-06-13 15:41:11 -05:00
}
2020-06-15 21:30:39 -05:00
2020-06-13 16:15:53 -05:00
.btn-circle.disabled {
2020-06-13 15:41:11 -05:00
opacity: 1;
2020-06-15 21:30:39 -05:00
background-color: #62bcca;
border-color: #64c0ce;
2020-06-13 15:41:11 -05:00
}
2020-06-13 09:35:28 -05:00
.install-progress {
2020-06-13 16:15:53 -05:00
margin: auto -1px auto 0;
2020-06-13 15:41:11 -05:00
height: 14px;
2020-06-13 16:15:53 -05:00
display: inline-block;
2020-06-13 09:35:28 -05:00
width: 100%;
2020-06-13 15:41:11 -05:00
background-color: lightgray;
box-shadow:
inset 0 6px 4px -5px black,
inset 0 -6px 4px -7px black;
}
2020-06-13 16:15:53 -05:00
.install-progress.loop {
box-shadow:
inset 0 6px 4px -5px black,
inset 0 -6px 4px -7px black,
inset 8px 0 4px -6px grey; /* missing button shadow */
}
2020-06-13 15:41:11 -05:00
.install-progress.complete {
2020-06-13 16:15:53 -05:00
background-color: #db202e;
2020-06-13 15:41:11 -05:00
}
#step-title {
padding-bottom: 20px;
2020-06-13 09:35:28 -05:00
}
2020-06-06 17:26:25 -05:00
</style>
2020-06-07 00:03:57 -05:00
@yield('style')
2020-06-05 14:26:57 -05:00
</head>
2020-06-07 00:03:57 -05:00
<body>
2020-06-05 14:26:57 -05:00
<div class="container">
2020-06-07 10:36:45 -05:00
<div class="card col-lg-8 offset-lg-2 col-md-10 offset-md-1 col-12 primary-panel">
2020-06-13 15:41:11 -05:00
<div class="card-img-top">
2020-06-13 16:15:53 -05:00
<img class="card-img-top p-4" src="{{ asset(\LibreNMS\Config::get('title_image', "images/librenms_logo_light.svg")) }}" alt="LibreNMS">
2020-06-13 09:35:28 -05:00
<div id="progress-icons" class="d-flex flex-row justify-content-around">
2020-06-13 15:41:11 -05:00
<div class="install-progress complete"></div>
2020-06-11 01:06:16 -05:00
@foreach($steps as $step => $controller)
<div>
<a href="{{ route('install.' . $step) }}"
2020-06-17 06:59:19 -05:00
class="install-enable-{{ $step }} btn btn-info btn-circle @if(!$controller->enabled($steps)) disabled @endif"
2020-06-11 01:06:16 -05:00
title="@lang("install.$step.title")"
>
2020-06-15 00:45:40 -05:00
<i class="fa fa-lg {{ $controller->icon() }}"></i>
2020-06-11 01:06:16 -05:00
</a>
</div>
2020-06-15 00:45:40 -05:00
<div id="progress-{{ $step }}-bar" class="install-progress loop @if($controller->complete()) complete @endif"></div>
2020-06-11 01:06:16 -05:00
@endforeach
</div>
2020-06-13 15:41:11 -05:00
</div>
<div class="card-body">
<div class="row">
<div class="col-12 text-center">
<h2 id="step-title">@yield('title')</h2>
</div>
</div>
2020-06-06 17:26:25 -05:00
<div class="row">
2020-06-07 10:36:45 -05:00
<div id="error-box" class="col-12">
2020-06-08 02:21:03 -05:00
@if(!empty($messages))
@foreach($messages as $message)
2020-06-07 00:03:57 -05:00
<div class="alert alert-danger">{{ $message }}</div>
2020-06-08 02:21:03 -05:00
@endforeach
2020-06-06 17:26:25 -05:00
@endif
2020-06-05 15:50:23 -05:00
</div>
2020-06-06 17:26:25 -05:00
</div>
@yield('content')
</div>
</div>
2020-06-05 14:26:57 -05:00
</div>
2020-06-11 01:58:42 -05:00
<script>
function checkStepStatus() {
$.ajax('{{ route('install.action.steps') }}')
.success(function (data) {
console.log(data);
Object.keys(data).forEach(function (key) {
if (data[key]) {
2020-06-17 06:59:19 -05:00
$('.install-enable-' + key).removeClass('disabled');
$('.install-show-' + key).show();
2020-06-11 01:58:42 -05:00
} else {
2020-06-17 06:59:19 -05:00
$('.install-enable-' + key).addClass('disabled');
$('.install-show-' + key).hide();
2020-06-11 01:58:42 -05:00
}
});
})
}
</script>
2020-06-05 18:35:51 -05:00
@yield('scripts')
2020-06-05 14:26:57 -05:00
</body>
</html>