Compare commits
28 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
8b83990a66 | ||
|
4472202afb | ||
|
2040266ab2 | ||
|
1774987dea | ||
|
6c60298e8f | ||
|
41b320a5b9 | ||
|
1096f0e28d | ||
|
b0730b9ed3 | ||
|
163a7f2587 | ||
|
4f2707a374 | ||
|
0ca66c6d1c | ||
|
5833122ab5 | ||
|
a946ce4418 | ||
|
e5ff189d3e | ||
|
1efdfca55f | ||
|
6d876f2c94 | ||
|
70a7142877 | ||
|
c406c35ff7 | ||
|
6d84613158 | ||
|
05dbcaf6c4 | ||
|
867b42be91 | ||
|
f44e6f1d09 | ||
|
fb88cf2866 | ||
|
91aa1d9378 | ||
|
062b1bce8c | ||
|
11a321603c | ||
|
8aa21663d5 | ||
|
3af5ae6466 |
@@ -10,8 +10,9 @@
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"igaster/laravel-theme": "2.0.6",
|
"igaster/laravel-theme": "^2.0.15",
|
||||||
"orchestra/asset": "^3.6"
|
"creativeorange/gravatar": "^1.0",
|
||||||
|
"orchestra/asset": "^4.0"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
},
|
},
|
||||||
|
@@ -29,10 +29,11 @@ return [
|
|||||||
'signGithub' => 'Sign in using Github',
|
'signGithub' => 'Sign in using Github',
|
||||||
'signFacebook' => 'Sign in using Facebook',
|
'signFacebook' => 'Sign in using Facebook',
|
||||||
'signTwitter' => 'Sign in using Twitter',
|
'signTwitter' => 'Sign in using Twitter',
|
||||||
'signGoogle+' => 'Sign in using Google+',
|
'signGoogle' => 'Sign in using Google',
|
||||||
'signLinkedin' => 'Sign in using Linkedin',
|
'signLinkedin' => 'Sign in using Linkedin',
|
||||||
'signW3id' => 'Sign in using W3id',
|
'signW3id' => 'Sign in using W3id',
|
||||||
'signIBMid' => 'Sign in using IBMid',
|
'signIBMid' => 'Sign in using IBMid',
|
||||||
|
'signMeetup' => 'Sign in using Meetup',
|
||||||
'sendpassword' => 'Send Password Reset Link',
|
'sendpassword' => 'Send Password Reset Link',
|
||||||
'passwordreset' => 'Reset password',
|
'passwordreset' => 'Reset password',
|
||||||
'pagenotfound' => 'Page not found',
|
'pagenotfound' => 'Page not found',
|
||||||
|
@@ -5,12 +5,19 @@
|
|||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<body class="hold-transition login-page">
|
@if(isset($login_note) AND $login_note)
|
||||||
<div id="app" v-cloak>
|
<div class="alert alert-info alert-dismissible m-auto">
|
||||||
<div class="login-box">
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
|
<h5><i class="icon fa fa-info"></i> NOTE!</h5>
|
||||||
|
{!! $login_note !!}
|
||||||
|
</div>
|
||||||
|
<br>
|
||||||
|
@endisset
|
||||||
|
|
||||||
|
<div class="login-box m-auto">
|
||||||
<div class="login-logo">
|
<div class="login-logo">
|
||||||
<a href="{{ url('/home') }}">{!! config('app.name_html_long') !!}</a>
|
<a>{!! config('app.name_html_long') !!}</a>
|
||||||
</div><!-- /.login-logo -->
|
</div>
|
||||||
|
|
||||||
@if (count($errors) > 0)
|
@if (count($errors) > 0)
|
||||||
<div class="alert alert-danger">
|
<div class="alert alert-danger">
|
||||||
@@ -23,32 +30,66 @@
|
|||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
<div class="login-box-body">
|
@if (Session::has('error'))
|
||||||
|
<div class="alert alert-danger">
|
||||||
|
<strong>Whoops!</strong> {{ trans('adminlte_lang::message.someproblems') }}<br><br>
|
||||||
|
<ul>
|
||||||
|
<li>{{ Session::get('error') }}</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
<!-- /.login-logo -->
|
||||||
|
<div class="card">
|
||||||
|
<div class="card-body login-card-body">
|
||||||
<p class="login-box-msg">{{ trans('adminlte_lang::message.siginsession') }}</p>
|
<p class="login-box-msg">{{ trans('adminlte_lang::message.siginsession') }}</p>
|
||||||
|
|
||||||
<login-form name="{{ config('auth.providers.users.field','email') }}"
|
<form method="post">
|
||||||
domain="{{ config('auth.defaults.domain','') }}"></login-form>
|
{{ csrf_field() }}
|
||||||
|
<div class="input-group mb-3">
|
||||||
<a href="{{ url('/password/reset') }}">{{ trans('adminlte_lang::message.forgotpassword') }}</a><br>
|
<input type="email" name="email" class="form-control" placeholder="Email">
|
||||||
|
<div class="input-group-append">
|
||||||
|
<span class="fa fa-envelope input-group-text"></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="input-group mb-3">
|
||||||
|
<input type="password" name="password" class="form-control" placeholder="Password">
|
||||||
|
<div class="input-group-append">
|
||||||
|
<span class="fa fa-lock input-group-text"></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-8">
|
||||||
|
<div class="checkbox icheck">
|
||||||
|
<label>
|
||||||
|
<input type="checkbox" name="remember"> Remember Me
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- /.col -->
|
||||||
|
<div class="col-4">
|
||||||
|
<button type="submit" name="submit" class="btn btn-primary btn-block btn-flat">Sign In</button>
|
||||||
|
</div>
|
||||||
|
<!-- /.col -->
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
|
||||||
@if(count(config('auth.social',[])))
|
@if(count(config('auth.social',[])))
|
||||||
@include('adminlte::auth.partials.social_login')
|
@include('adminlte::auth.partials.social_login')
|
||||||
@endif
|
@endif
|
||||||
</div><!-- /.login-box-body -->
|
|
||||||
|
|
||||||
</div><!-- /.login-box -->
|
<p class="mb-1">
|
||||||
|
<a name="reset" href="{{ url('/password/reset') }}">{{ trans('adminlte_lang::message.forgotpassword') }}</a>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
@isset($register)
|
||||||
|
<p class="mb-0">
|
||||||
|
<a href="register.html" class="text-center">Register a new membership</a>
|
||||||
|
</p>
|
||||||
|
@endisset
|
||||||
</div>
|
</div>
|
||||||
|
<!-- /.login-card-body -->
|
||||||
@include('adminlte::layouts.partials.scripts_auth')
|
</div>
|
||||||
|
</div>
|
||||||
<script>
|
<!-- /.login-box -->
|
||||||
$(function () {
|
|
||||||
$('input').iCheck({
|
|
||||||
checkboxClass: 'icheckbox_square-blue',
|
|
||||||
radioClass: 'iradio_square-blue',
|
|
||||||
increaseArea: '20%' // optional
|
|
||||||
});
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
</body>
|
|
||||||
@endsection
|
@endsection
|
@@ -0,0 +1,14 @@
|
|||||||
|
<!-- Compiled app javascript -->
|
||||||
|
<script src="{{ asset('/js/app.js') }}"></script>
|
||||||
|
<!-- iCheck -->
|
||||||
|
<script src="{{ asset('/plugin/iCheck/icheck.min.js') }}"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$(document).ready(function() {
|
||||||
|
$('input').iCheck({
|
||||||
|
checkboxClass: 'icheckbox_square-blue',
|
||||||
|
radioClass : 'iradio_square-blue',
|
||||||
|
increaseArea : '20%' // optional
|
||||||
|
})
|
||||||
|
})
|
||||||
|
</script>
|
@@ -1,6 +1,9 @@
|
|||||||
<div class="social-auth-links text-center">
|
<div class="social-auth-links text-center mb-3">
|
||||||
<p>- OR -</p>
|
<p>- OR -</p>
|
||||||
@foreach(config('auth.social') as $o)
|
@foreach(config('auth.social') as $o)
|
||||||
<a href="{{ url('/auth/'.$o['id']) }}" class="btn btn-block btn-social btn-{{ $o['class'] }} btn-flat"><i class="fa fa-{{ $o['icon'] }}"></i> {{ trans('adminlte_lang::message.sign'.$o['name']) }}</a>
|
<a href="{{ url('/auth/'.$o['id']) }}" class="btn btn-block btn-{{ $o['class'] }}">
|
||||||
|
<i class="fa fa-{{ $o['icon'] }} mr-2"></i> {{ trans('adminlte_lang::message.sign'.$o['name']) }}
|
||||||
|
</a>
|
||||||
@endforeach
|
@endforeach
|
||||||
</div><!-- /.social-auth-links -->
|
</div>
|
||||||
|
<!-- /.social-auth-links -->
|
@@ -1,44 +0,0 @@
|
|||||||
@extends('adminlte::layouts.auth')
|
|
||||||
|
|
||||||
@section('htmlheader_title')
|
|
||||||
Register
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('content')
|
|
||||||
|
|
||||||
<body class="hold-transition register-page">
|
|
||||||
<div id="app" v-cloak>
|
|
||||||
<div class="register-box">
|
|
||||||
<div class="register-logo">
|
|
||||||
<a href="{{ url('/home') }}">{!! config('app.name_html_long') !!}</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
@if (count($errors) > 0)
|
|
||||||
<div class="alert alert-danger">
|
|
||||||
<strong>Whoops!</strong> {{ trans('adminlte_lang::message.someproblems') }}<br><br>
|
|
||||||
<ul>
|
|
||||||
@foreach ($errors->all() as $error)
|
|
||||||
<li>{{ $error }}</li>
|
|
||||||
@endforeach
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
@endif
|
|
||||||
|
|
||||||
<div class="register-box-body">
|
|
||||||
<p class="login-box-msg">Register for access</p>
|
|
||||||
|
|
||||||
<register-form></register-form>
|
|
||||||
<!-- #include('adminlte::auth.partials.social_login') -->
|
|
||||||
|
|
||||||
<a href="{{ url('/login') }}" class="text-center">I already have an account</a>
|
|
||||||
</div><!-- /.form-box -->
|
|
||||||
</div><!-- /.register-box -->
|
|
||||||
</div>
|
|
||||||
|
|
||||||
@include('adminlte::layouts.partials.scripts_auth')
|
|
||||||
|
|
||||||
@include('adminlte::auth.terms')
|
|
||||||
|
|
||||||
</body>
|
|
||||||
|
|
||||||
@endsection
|
|
@@ -1,20 +0,0 @@
|
|||||||
@extends('adminlte::layouts.errors')
|
|
||||||
|
|
||||||
@section('htmlheader_title')
|
|
||||||
{{ trans('adminlte_lang::message.servererror') }}
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('main-content')
|
|
||||||
|
|
||||||
<div class="error-page">
|
|
||||||
<h2 class="headline text-red">403</h2>
|
|
||||||
<div class="error-content">
|
|
||||||
<h3><i class="fa fa-warning text-red"></i> Oops! Bad Authentication</h3>
|
|
||||||
<p>
|
|
||||||
Sorry, your authentication failed.
|
|
||||||
{{ trans('adminlte_lang::message.mainwhile') }} <a href='{{ url('/home') }}'>{{ trans('adminlte_lang::message.returndashboard') }}</a>.
|
|
||||||
</p>
|
|
||||||
<br>
|
|
||||||
</div>
|
|
||||||
</div><!-- /.error-page -->
|
|
||||||
@endsection
|
|
@@ -1,20 +0,0 @@
|
|||||||
@extends('adminlte::layouts.errors')
|
|
||||||
|
|
||||||
@section('htmlheader_title')
|
|
||||||
{{ trans('adminlte_lang::message.pagenotfound') }}
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('main-content')
|
|
||||||
|
|
||||||
<div class="error-page">
|
|
||||||
<h2 class="headline text-yellow">404</h2>
|
|
||||||
<div class="error-content">
|
|
||||||
<h3><i class="fa fa-warning text-yellow"></i> Oops! {{ trans('adminlte_lang::message.pagenotfound') }}.</h3>
|
|
||||||
<p>
|
|
||||||
{{ trans('adminlte_lang::message.notfindpage') }}
|
|
||||||
{{ trans('adminlte_lang::message.mainwhile') }} <a href='{{ url('/home') }}'>{{ trans('adminlte_lang::message.returndashboard') }}</a>.
|
|
||||||
</p>
|
|
||||||
<br/>
|
|
||||||
</div><!-- /.error-content -->
|
|
||||||
</div><!-- /.error-page -->
|
|
||||||
@endsection
|
|
@@ -1,20 +0,0 @@
|
|||||||
@extends('adminlte::layouts.errors')
|
|
||||||
|
|
||||||
@section('htmlheader_title')
|
|
||||||
{{ trans('adminlte_lang::message.servererror') }}
|
|
||||||
@endsection
|
|
||||||
|
|
||||||
@section('main-content')
|
|
||||||
|
|
||||||
<div class="error-page">
|
|
||||||
<h2 class="headline text-red">500</h2>
|
|
||||||
<div class="error-content">
|
|
||||||
<h3><i class="fa fa-warning text-red"></i> Oops! {{ trans('adminlte_lang::message.somethingwrong') }}</h3>
|
|
||||||
<h4><i class="text-red"></i> {{ trans($msg) }}</h4>
|
|
||||||
<p>
|
|
||||||
{{ trans('adminlte_lang::message.wewillwork') }}
|
|
||||||
{{ trans('adminlte_lang::message.mainwhile') }} <a href='{{ url('/home') }}'>{{ trans('adminlte_lang::message.returndashboard') }}</a>.
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div><!-- /.error-page -->
|
|
||||||
@endsection
|
|
@@ -1,11 +1,10 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
|
@section('htmlheader')
|
||||||
@section('htmlheader')
|
|
||||||
@include('adminlte::layouts.partials.htmlheader')
|
@include('adminlte::layouts.partials.htmlheader')
|
||||||
@show
|
@show
|
||||||
|
|
||||||
<body class="fixed hold-transition skin-blue sidebar-mini">
|
<body class="hold-transition sidebar-mini @if (Cookie::get('toggleState') === 'closed') {{ 'sidebar-collapse' }} @endif">
|
||||||
<div id="app">
|
<div id="app">
|
||||||
<div class="wrapper">
|
<div class="wrapper">
|
||||||
@include('adminlte::layouts.partials.mainheader')
|
@include('adminlte::layouts.partials.mainheader')
|
||||||
@@ -19,7 +18,7 @@
|
|||||||
|
|
||||||
<!-- Main content -->
|
<!-- Main content -->
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="row">
|
<div class="container-fluid">
|
||||||
<!-- Your Page Content Here -->
|
<!-- Your Page Content Here -->
|
||||||
@yield('main-content')
|
@yield('main-content')
|
||||||
</div>
|
</div>
|
||||||
@@ -27,18 +26,21 @@
|
|||||||
|
|
||||||
</div><!-- /.content-wrapper -->
|
</div><!-- /.content-wrapper -->
|
||||||
|
|
||||||
<!-- #include('adminlte::layouts.partials.controlsidebar') -->
|
@isset($controlsidebar)
|
||||||
|
@include('adminlte::layouts.partials.controlsidebar')
|
||||||
|
@endisset
|
||||||
|
|
||||||
@include('adminlte::layouts.partials.footer')
|
@include('adminlte::layouts.partials.footer')
|
||||||
</div><!-- ./wrapper -->
|
</div><!-- ./wrapper -->
|
||||||
</div> <!-- ./app -->
|
</div> <!-- ./app -->
|
||||||
|
|
||||||
@section('scripts')
|
@section('scripts')
|
||||||
@include('adminlte::layouts.partials.scripts')
|
@include('adminlte::layouts.partials.scripts')
|
||||||
|
|
||||||
{{-- Scripts --}}
|
{{-- Scripts --}}
|
||||||
{!! Asset::scripts() !!}
|
{!! Asset::scripts() !!}
|
||||||
|
|
||||||
@yield('page-scripts')
|
@yield('page-scripts')
|
||||||
@show
|
@show
|
||||||
|
</body>
|
||||||
</body>
|
|
||||||
</html>
|
</html>
|
@@ -1,8 +1,19 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
|
@section('htmlheader')
|
||||||
|
@include('adminlte::layouts.partials.htmlheader')
|
||||||
|
|
||||||
@include('adminlte::layouts.partials.htmlheader')
|
<!-- iCheck -->
|
||||||
|
<link rel="stylesheet" href="{{ asset('/plugin/iCheck/square/blue.css') }}">
|
||||||
|
@show
|
||||||
|
|
||||||
@yield('content')
|
<body class="hold-transition login-page">
|
||||||
|
<div id="app">
|
||||||
|
@yield('content')
|
||||||
|
</div>
|
||||||
|
|
||||||
|
@section('scripts')
|
||||||
|
@include('adminlte::auth.partials.scripts')
|
||||||
|
@show
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
@@ -1,17 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html>
|
|
||||||
|
|
||||||
@include('adminlte::layouts.partials.htmlheader')
|
|
||||||
<body>
|
|
||||||
<div id="app" v-cloak>
|
|
||||||
<!-- Main content -->
|
|
||||||
<section class="content">
|
|
||||||
<!-- Your Page Content Here -->
|
|
||||||
@yield('main-content')
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
@section('scripts')
|
|
||||||
@include('adminlte::layouts.partials.scripts')
|
|
||||||
@show
|
|
||||||
</body>
|
|
||||||
</html>
|
|
@@ -1,17 +1,24 @@
|
|||||||
<!-- Content Header (Page header) -->
|
<!-- Content Header (Page header) -->
|
||||||
<section class="content-header">
|
<div class="content-header d-print-none">
|
||||||
<div id="search_results"></div>
|
<div class="container-fluid">
|
||||||
<h1>
|
<div class="row mb-2">
|
||||||
@yield('contentheader_title', 'Content Title')
|
<div class="col-sm-6">
|
||||||
<small>@yield('contentheader_description')</small>
|
<h1 class="m-0 text-dark">@yield('contentheader_title', 'Content Title')</h1>
|
||||||
</h1>
|
<small>@yield('contentheader_description','Description')</small>
|
||||||
<ol class="breadcrumb">
|
</div><!-- /.col -->
|
||||||
<li><a href="{{ url('/home'.(isset($ido) ? '/'.$ido->id : '')) }}"><i class="fa fa-dashboard"></i>Home</a></li>
|
|
||||||
|
|
||||||
|
<div class="col-sm-6">
|
||||||
|
<ol class="breadcrumb float-sm-right small">
|
||||||
|
<li class="breadcrumb-item"><a href="{{ url('/home'.(isset($ido) ? '/'.$ido->id : '')) }}">Home</a></li>
|
||||||
@isset($breadcrumb)
|
@isset($breadcrumb)
|
||||||
@foreach ($breadcrumb as $item => $url)
|
@foreach ($breadcrumb as $item => $url)
|
||||||
<li><a href="{{url($url)}}">{{ $item }}</a></li>
|
<li class="breadcrumb-item"><a href="{{url($url)}}">{{ $item }}</a></li>
|
||||||
@endforeach
|
@endforeach
|
||||||
@endisset
|
@endisset
|
||||||
</ol> <!-- /.breadcrumb -->
|
<li class="breadcrumb-item active">@yield('page_title','Page Title')</li>
|
||||||
</section> <!-- /.content-header -->
|
</ol>
|
||||||
|
</div><!-- /.col -->
|
||||||
|
</div><!-- /.row -->
|
||||||
|
</div><!-- /.container-fluid -->
|
||||||
|
</div>
|
||||||
|
<!-- /.content-header -->
|
@@ -0,0 +1,5 @@
|
|||||||
|
<!-- Control Sidebar -->
|
||||||
|
<aside class="control-sidebar control-sidebar-dark">
|
||||||
|
<!-- Control sidebar content goes here -->
|
||||||
|
</aside>
|
||||||
|
<!-- /.control-sidebar -->
|
@@ -1,8 +1,10 @@
|
|||||||
<!-- Main Footer -->
|
<!-- Main Footer -->
|
||||||
<footer class="main-footer no-print">
|
<footer class="main-footer">
|
||||||
<!-- To the right -->
|
<!-- To the right -->
|
||||||
<div class="pull-right hidden-xs">
|
<div class="float-right d-sm-none d-md-block">
|
||||||
<a href="#"></a><b>{{ config('app.name') }}</b></a>
|
{{ config('app.name') }}
|
||||||
</div>
|
</div>
|
||||||
<strong>© Leenooks</strong>
|
|
||||||
|
<!-- Default to the left -->
|
||||||
|
<strong>Copyright © 2014-2018 <a href="#">© Leenooks</a>.</strong> All rights reserved.
|
||||||
</footer>
|
</footer>
|
@@ -6,7 +6,24 @@
|
|||||||
<!-- CSRF Token -->
|
<!-- CSRF Token -->
|
||||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
<meta name="csrf-token" content="{{ csrf_token() }}">
|
||||||
|
|
||||||
<link href="{{ asset('/css/all.css') }}" rel="stylesheet" type="text/css" />
|
<link rel="stylesheet" href="{{ asset('/css/app.css') }}">
|
||||||
|
|
||||||
|
<!-- Font Awesome Icons -->
|
||||||
|
<link rel="stylesheet" href="{{ asset('/plugin/font-awesome/css/font-awesome.min.css') }}">
|
||||||
|
<!-- IonIcons -->
|
||||||
|
<link rel="stylesheet" href="{{ request()->getScheme() }}://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
|
||||||
|
|
||||||
|
<!-- Google Font: Source Sans Pro -->
|
||||||
|
<link href="{{ request()->getScheme() }}://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700" rel="stylesheet">
|
||||||
|
|
||||||
|
@if(file_exists('css/social.css'))
|
||||||
|
<!-- Social Logins -->
|
||||||
|
<link rel="stylesheet" href="{{ asset('/css/social.css') }}">
|
||||||
|
@endif
|
||||||
|
@if(file_exists('css/print.css'))
|
||||||
|
<!-- Printing Modifications -->
|
||||||
|
<link rel="stylesheet" href="{{ asset('/css/print.css') }}">
|
||||||
|
@endif
|
||||||
|
|
||||||
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
|
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
|
||||||
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
|
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
|
||||||
@@ -15,50 +32,19 @@
|
|||||||
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
|
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
|
||||||
<![endif]-->
|
<![endif]-->
|
||||||
|
|
||||||
<style type="text/css">
|
|
||||||
@media screen, print {
|
|
||||||
body {
|
|
||||||
color: #333;
|
|
||||||
font-weight: 400;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
label {
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@media print {
|
|
||||||
body {
|
|
||||||
font-size: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
tr { page-break-inside:avoid; }
|
|
||||||
thead { display:table-header-group; }
|
|
||||||
tfoot { display:table-footer-group; }
|
|
||||||
|
|
||||||
.table-responsive {
|
|
||||||
overflow: visible !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
//See https://laracasts.com/discuss/channels/vue/use-trans-in-vuejs
|
|
||||||
window.trans =
|
|
||||||
@php
|
|
||||||
// copy all translations from /resources/lang/CURRENT_LOCALE/* to global JS variable
|
|
||||||
$lang_files = File::files(resource_path() . '/lang/' . App::getLocale());
|
|
||||||
$trans = [];
|
|
||||||
foreach ($lang_files as $f) {
|
|
||||||
$filename = pathinfo($f)['filename'];
|
|
||||||
$trans[$filename] = trans($filename);
|
|
||||||
}
|
|
||||||
$trans['adminlte_lang_message'] = trans('adminlte_lang::message');
|
|
||||||
echo json_encode($trans);
|
|
||||||
@endphp
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<!-- STYLESHEETS -->
|
<!-- STYLESHEETS -->
|
||||||
{!! Asset::styles() !!}
|
{!! Asset::styles() !!}
|
||||||
|
|
||||||
|
<!-- Theme style -->
|
||||||
|
<link rel="stylesheet" href="{{ asset('/css/adminlte.min.css') }}">
|
||||||
|
|
||||||
|
@if(file_exists('css/fixes.css'))
|
||||||
|
<!-- CSS Fixes -->
|
||||||
|
<link rel="stylesheet" href="{{ asset('/css/fixes.css') }}">
|
||||||
|
@endif
|
||||||
|
|
||||||
|
@if(file_exists('css/custom.css'))
|
||||||
|
<!-- Custom CSS -->
|
||||||
|
<link rel="stylesheet" href="{{ asset('/css/custom.css') }}">
|
||||||
|
@endif
|
||||||
</head>
|
</head>
|
@@ -1,104 +1,153 @@
|
|||||||
<!-- Main Header -->
|
<!-- Main Header -->
|
||||||
<header class="main-header">
|
<!-- Navbar -->
|
||||||
|
<nav class="main-header navbar navbar-expand bg-white navbar-light border-bottom">
|
||||||
<!-- Logo -->
|
<!-- Left navbar links -->
|
||||||
<a href="{{ url('/home') }}" class="logo">
|
<ul class="navbar-nav">
|
||||||
<!-- mini logo for sidebar mini 50x50 pixels -->
|
<li class="nav-item">
|
||||||
<span class="logo-mini">{!! config('app.name_html_short','<b>A</b>N') !!}</span>
|
<a class="nav-link" data-widget="pushmenu" href="#"><i class="fa fa-bars"></i></a>
|
||||||
<!-- logo for regular state and mobile devices -->
|
|
||||||
<span class="logo-lg">{!! config('app.name_html_long','<b>App</b>Name') !!}</span>
|
|
||||||
</a>
|
|
||||||
|
|
||||||
<!-- Header Navbar -->
|
|
||||||
<nav class="navbar navbar-static-top" role="navigation">
|
|
||||||
<!-- Sidebar toggle button-->
|
|
||||||
<a href="#" class="sidebar-toggle" data-toggle="push-menu" role="button">
|
|
||||||
<span class="sr-only">{{ trans('adminlte_lang::message.togglenav') }}</span>
|
|
||||||
</a>
|
|
||||||
<!-- Navbar Right Menu -->
|
|
||||||
<div class="navbar-custom-menu">
|
|
||||||
<ul class="nav navbar-nav">
|
|
||||||
<!-- Tasks Menu -->
|
|
||||||
@if (Auth::guest())
|
|
||||||
<li><a href="{{ url('/register') }}">{{ trans('adminlte_lang::message.register') }}</a></li>
|
|
||||||
<li><a href="{{ url('/login') }}">{{ trans('adminlte_lang::message.login') }}</a></li>
|
|
||||||
@else
|
|
||||||
|
|
||||||
@if (isset($topmenu))
|
|
||||||
<!-- Available Data Menu -->
|
|
||||||
<li class="dropdown tasks-menu" id="import_date">
|
|
||||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
|
|
||||||
<span class="hidden-xs">Items</span>
|
|
||||||
</a>
|
|
||||||
<ul class="dropdown-menu">
|
|
||||||
<li class="header">Header</li>
|
|
||||||
<li>
|
|
||||||
<ul class="menu small">
|
|
||||||
|
|
||||||
</ul>
|
|
||||||
</li>
|
</li>
|
||||||
<li class="footer"><a href="#">(Not Active)</a></li>
|
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
|
||||||
@endif
|
|
||||||
|
|
||||||
<!-- Top Menu Items -->
|
<!-- SEARCH FORM -->
|
||||||
|
<form class="form-inline ml-3">
|
||||||
|
<div class="input-group input-group-sm">
|
||||||
|
<input class="form-control form-control-navbar" name="q" type="search" placeholder="Search" aria-label="Search" autocomplete="off">
|
||||||
|
<div class="input-group-append">
|
||||||
|
<button class="btn btn-navbar" type="submit">
|
||||||
|
<i class="fa fa-search"></i>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
<span name="searching" class="d-none"><i class="fa fa-spinner fa-spin fa-fw" style="margin-top: .33em; width: 1em; height: 1em;"></i></span>
|
||||||
|
<div id="search_results"></div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
|
||||||
|
<!-- Right navbar links -->
|
||||||
|
<ul class="navbar-nav ml-auto">
|
||||||
@include('adminlte::layouts.partials.topmenu')
|
@include('adminlte::layouts.partials.topmenu')
|
||||||
|
|
||||||
<li class="dropdown user user-menu @if($user->switched) bg-red @endif" id="user_menu">
|
@if(Auth::check())
|
||||||
<!-- Menu Toggle Button -->
|
<!-- Profile Settings -->
|
||||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
|
<li class="nav-item dropdown">
|
||||||
<!-- The user image in the navbar-->
|
<a class="nav-link" data-toggle="dropdown" href="#">
|
||||||
<img src="{{ Gravatar::get($user->email) }}" class="user-image" alt="User Image"/>
|
<i class="fa fa-cog"></i>
|
||||||
<!-- hidden-xs hides the username on small devices so only the image appears. -->
|
|
||||||
<span class="hidden-xs">{{ $user->name }}</span>
|
|
||||||
</a>
|
</a>
|
||||||
<ul class="dropdown-menu">
|
<div class="dropdown-menu dropdown-menu-lg dropdown-menu-right">
|
||||||
<!-- The user image in the menu -->
|
<span class="dropdown-item dropdown-header @if($user->switched) bg-danger @endif">
|
||||||
<li class="user-header">
|
@if($user->switched)
|
||||||
<img src="{{ Gravatar::get($user->email) }}" class="img-circle" alt="User Image" />
|
SUDO (<small>{{ $user->name ?: 'User Name' }}</small>)
|
||||||
<p>
|
@else
|
||||||
{{ $user->name }}
|
{{ $user->name ?: 'User Name' }}
|
||||||
<small>{{ trans('adminlte_lang::message.login') }}: @if($user->last_access) {{ $user->last_access->format('Y-m-d') }} @else Unknown @endif</small>
|
@endif
|
||||||
</p>
|
</span>
|
||||||
</li>
|
|
||||||
<!-- Menu Footer-->
|
|
||||||
<li class="user-footer">
|
|
||||||
<div class="pull-left">
|
|
||||||
<a href="{{ url('/settings') }}" class="btn btn-default btn-flat">{{ trans('adminlte_lang::message.profile') }}</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="pull-right">
|
<div class="dropdown-divider"></div>
|
||||||
|
<a href="{{ url('settings') }}" class="dropdown-item">
|
||||||
|
<i class="fa fa-user mr-2"></i> Settings
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="dropdown-divider"></div>
|
||||||
@if ($user->switched)
|
@if ($user->switched)
|
||||||
<a href="{{ url('/admin/switch/stop') }}" class="btn btn-default btn-flat" id="switch">
|
<a href="{{ url('/admin/switch/stop') }}" class="dropdown-item" id="switch">
|
||||||
{{ trans('adminlte_lang::message.switchoff') }}
|
<i class="fa fa-sign-out mr-2"></i> {{ trans('adminlte_lang::message.switchoff') }}
|
||||||
</a>
|
</a>
|
||||||
@else
|
@else
|
||||||
<a href="{{ url('/logout') }}" class="btn btn-default btn-flat" id="logout"
|
<a href="{{ url('logout') }}" class="dropdown-item">
|
||||||
onclick="event.preventDefault();
|
<i class="fa fa-sign-out mr-2"></i> Log Out
|
||||||
document.getElementById('logout-form').submit();">
|
|
||||||
{{ trans('adminlte_lang::message.signout') }}
|
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
<form id="logout-form" action="{{ url('/logout') }}" method="POST" style="display: none;">
|
|
||||||
{{ csrf_field() }}
|
|
||||||
<input type="submit" value="logout" style="display: none;">
|
|
||||||
</form>
|
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
@else
|
||||||
</li>
|
<a href="{{ url('login') }}" class="text-muted pr-2"><i class="fa fa-lock"></i></a>
|
||||||
|
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
<!-- Control Sidebar Toggle Button -->
|
<!-- Control Side Bar -->
|
||||||
@if (isset($controlbar))
|
@isset($controlsidebar)
|
||||||
<li>
|
<li class="nav-item">
|
||||||
<a href="#" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a>
|
<a class="nav-link" data-widget="control-sidebar" data-slide="true" href="#">
|
||||||
|
<i class="fa fa-th-large"></i>
|
||||||
|
</a>
|
||||||
</li>
|
</li>
|
||||||
@endif
|
@endisset
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</nav>
|
||||||
</nav>
|
|
||||||
</header>
|
@section('page-scripts')
|
||||||
|
@js('/plugin/bootstrap3-typeahead/js/bootstrap3-typeahead.min.js','bs-typeahead')
|
||||||
|
|
||||||
|
<script type="text/javascript">
|
||||||
|
$(document).ready(function() {
|
||||||
|
$("input[name=q]").typeahead({
|
||||||
|
delay: 500,
|
||||||
|
minLength: 2,
|
||||||
|
items: {{ isset($search_limit) ? $search_limit : 15 }},
|
||||||
|
fitToElement: false,
|
||||||
|
appendTo: "#search_results",
|
||||||
|
source: function (query,process) {
|
||||||
|
search('{{ url("search",['date'=>isset($ido) ? $ido->id : NULL]) }}',query,process);
|
||||||
|
},
|
||||||
|
|
||||||
|
matcher: function () { return true; },
|
||||||
|
|
||||||
|
updater: function (item) {
|
||||||
|
window.parent.location.href = '{{ url("/") }}'+users[item];
|
||||||
|
},
|
||||||
|
})
|
||||||
|
.on('keyup keypress', function(event) {
|
||||||
|
var key = event.keyCode || event.which;
|
||||||
|
if (key === 13) {
|
||||||
|
event.preventDefault();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
var c=0;
|
||||||
|
var search = _.debounce(function(url,query,process,icon){
|
||||||
|
$.ajax({
|
||||||
|
url : url,
|
||||||
|
type : 'GET',
|
||||||
|
data : 'term=' + query,
|
||||||
|
dataType : 'JSON',
|
||||||
|
async : true,
|
||||||
|
cache : false,
|
||||||
|
beforeSend : function() {
|
||||||
|
if (c++ == 0) {
|
||||||
|
if (icon)
|
||||||
|
$('i[name='+icon+']').addClass("fa-spin");
|
||||||
|
else {
|
||||||
|
$('span[name=searching]').removeClass("d-none");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
success : function(data) {
|
||||||
|
// if json is null, means no match, won't do again.
|
||||||
|
if(data==null || (data.length===0)) return;
|
||||||
|
|
||||||
|
users = {};
|
||||||
|
userLabels = [];
|
||||||
|
_.each(data,function(item,ix,list) {
|
||||||
|
if (_.includes(users,item.label))
|
||||||
|
item.label = item.label + ' #' + item.value;
|
||||||
|
|
||||||
|
userLabels.push(item.label);
|
||||||
|
users[item.label] = item.value;
|
||||||
|
});
|
||||||
|
|
||||||
|
process(userLabels);
|
||||||
|
},
|
||||||
|
complete : function() {
|
||||||
|
if (--c == 0) {
|
||||||
|
if (icon)
|
||||||
|
$('i[name='+icon+']').removeClass("fa-spin");
|
||||||
|
else {
|
||||||
|
$('span[name=searching]').addClass("d-none");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}, 500);
|
||||||
|
</script>
|
||||||
|
@append
|
@@ -1,22 +1,73 @@
|
|||||||
<!-- REQUIRED JS SCRIPTS -->
|
<!-- REQUIRED JS SCRIPTS -->
|
||||||
|
<!-- JQuery and bootstrap are required by Laravel 5.7 in resources/js/bootstrap.js-->
|
||||||
<!-- JQuery and bootstrap are required by Laravel 5.3 in resources/assets/js/bootstrap.js-->
|
|
||||||
<!-- Laravel App -->
|
<!-- Laravel App -->
|
||||||
<script src="{{ url(mix('/js/app.js')) }}" type="text/javascript"></script>
|
<script src="{{ asset('/js/app.js') }}" type="text/javascript"></script>
|
||||||
|
<!-- AdminLTE -->
|
||||||
|
<script src="{{ asset('/js/adminlte.min.js') }}"></script>
|
||||||
|
|
||||||
<!-- Our our CSRF token to each interaction -->
|
|
||||||
{{-- @todo Test that we are validating this, also axios should be doing this for us? --}}
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
// Our CSRF token to each interaction
|
||||||
$.ajaxSetup({
|
$.ajaxSetup({
|
||||||
headers: {
|
headers: {
|
||||||
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
|
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
</script>
|
|
||||||
|
|
||||||
<!-- Optionally, you can add Slimscroll and FastClick plugins.
|
$.AdminLTESidebarTweak = {};
|
||||||
Both of these plugins are recommended to enhance the
|
|
||||||
user experience. Slimscroll is required when using the
|
$.AdminLTESidebarTweak.options = {
|
||||||
fixed layout. -->
|
EnableRemember: true,
|
||||||
@js('/site/js/jquery.slimscroll.min.js','jq.slimscroll')
|
//Removes the transition after page reload.
|
||||||
@js('/site/js/fastclick.min.js','jq.fastclick')
|
NoTransitionAfterReload: false
|
||||||
|
};
|
||||||
|
|
||||||
|
// Work out our timezone.
|
||||||
|
const tz = Intl.DateTimeFormat().resolvedOptions().timeZone;
|
||||||
|
|
||||||
|
$(function () {
|
||||||
|
"use strict";
|
||||||
|
|
||||||
|
$("body").on("collapsed.lte.pushmenu", function(){
|
||||||
|
if($.AdminLTESidebarTweak.options.EnableRemember) {
|
||||||
|
document.cookie = "toggleState=closed;path=/";
|
||||||
|
|
||||||
|
$("body").delay(500).queue(function () {
|
||||||
|
window.dispatchEvent(new Event('resize'));
|
||||||
|
$(this).dequeue();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// @todo this is not firing.
|
||||||
|
$("body").on("shown.lte.pushmenu", function(){
|
||||||
|
if($.AdminLTESidebarTweak.options.EnableRemember){
|
||||||
|
document.cookie = "toggleState=opened;path=/";
|
||||||
|
|
||||||
|
$("body").delay(500).queue(function () {
|
||||||
|
window.dispatchEvent(new Event('resize'));
|
||||||
|
$(this).dequeue();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
if($.AdminLTESidebarTweak.options.EnableRemember){
|
||||||
|
var re = new RegExp('toggleState' + "=([^;]+)");
|
||||||
|
var value = re.exec(document.cookie);
|
||||||
|
var toggleState = (value != null) ? unescape(value[1]) : null;
|
||||||
|
if(toggleState == 'closed'){
|
||||||
|
if($.AdminLTESidebarTweak.options.NoTransitionAfterReload){
|
||||||
|
$("body").addClass('sidebar-collapse hold-transition').delay(100).queue(function(){
|
||||||
|
$(this).removeClass('hold-transition');
|
||||||
|
});
|
||||||
|
}else{
|
||||||
|
$("body")
|
||||||
|
.addClass('sidebar-collapse')
|
||||||
|
.delay(500).queue(function () {
|
||||||
|
window.dispatchEvent(new Event('resize'));
|
||||||
|
$(this).dequeue();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
</script>
|
@@ -1,2 +0,0 @@
|
|||||||
<!-- Compiled app javascript -->
|
|
||||||
<script src="{{ url (mix('/js/app.js')) }}"></script>
|
|
@@ -1,112 +1,37 @@
|
|||||||
<!-- Left side column. contains the logo and sidebar -->
|
<!-- Main Sidebar Container -->
|
||||||
<aside class="main-sidebar">
|
<aside class="main-sidebar sidebar-dark-primary elevation-4 d-print-none">
|
||||||
|
<!-- Brand Logo -->
|
||||||
<!-- sidebar: style can be found in sidebar.less -->
|
<a href="{{ url('home') }}" class="brand-link">
|
||||||
<section class="sidebar">
|
<img src="{{ asset('/img/logo.png') }}" alt="Logo" class="brand-image img-circle elevation-3" style="opacity: .8">
|
||||||
|
<span class="brand-text font-weight-light">{!! config('app.name_html_long','<b>App</b>Name') !!}</span>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<!-- Sidebar -->
|
||||||
|
<div class="sidebar">
|
||||||
<!-- Sidebar user panel (optional) -->
|
<!-- Sidebar user panel (optional) -->
|
||||||
@if (! Auth::guest())
|
<div class="user-panel mt-3 pb-3 mb-3 d-flex">
|
||||||
<div class="user-panel">
|
<div class="image">
|
||||||
<div class="pull-left image">
|
@if($user->exists)
|
||||||
<img src="{{ Gravatar::get($user->email) }}" class="img-circle" alt="User Image" />
|
<img src="{{ Gravatar::get(($user->exists AND $user->email) ? $user->email : 'nobody@example.com') }}" class="img-circle elevation-2" alt="User">
|
||||||
</div>
|
@else
|
||||||
<div class="pull-left info">
|
<a href="{{ url('login') }}" class="d-block"><i class="pl-1 fa fa-3x fa-lock"></i></a>
|
||||||
<p>{{ Auth::user()->name }}</p>
|
|
||||||
<!-- Status -->
|
|
||||||
<a href="#"><i class="fa fa-circle text-success"></i> {{ trans('adminlte_lang::message.online') }}</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
<!-- search form (Optional) -->
|
|
||||||
<form action="#" method="get" class="sidebar-form">
|
|
||||||
<div class="input-group">
|
|
||||||
<input type="text" name="q" class="form-control" autocomplete="off" placeholder="{{ trans('adminlte_lang::message.search') }}..."/>
|
|
||||||
<span class="input-group-btn">
|
|
||||||
<button type='submit' name='search' id='search-btn' class="btn btn-flat"><i class="fa fa-search"></i></button>
|
|
||||||
</span>
|
|
||||||
</div>
|
</div>
|
||||||
</form>
|
|
||||||
<!-- /.search form -->
|
<div class="info">
|
||||||
|
<a href="{{ url('login') }}" class="d-block">{{ $user->exists ? ($user->name ?: 'No Name') : 'Login' }}</a>
|
||||||
|
@isset($user->lastlogin)<a span="d-block"><small><span style="color: #747474;">Last On:</span> {{ $user->lastlogin->format('Y-m-d H:i') }}</small></a>@endisset
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!-- Sidebar Menu -->
|
<!-- Sidebar Menu -->
|
||||||
|
<nav class="mt-2">
|
||||||
|
<ul class="nav nav-pills nav-sidebar flex-column" data-widget="treeview" role="menu" data-accordion="false">
|
||||||
|
<!-- Add icons to the links using the .nav-icon class with font-awesome or any other icon font library -->
|
||||||
@include('adminlte::layouts.partials.sidebarmenu')
|
@include('adminlte::layouts.partials.sidebarmenu')
|
||||||
|
</ul>
|
||||||
|
</nav>
|
||||||
<!-- /.sidebar-menu -->
|
<!-- /.sidebar-menu -->
|
||||||
</section>
|
</div>
|
||||||
<!-- /.sidebar -->
|
<!-- /.sidebar -->
|
||||||
</aside>
|
</aside>
|
||||||
|
|
||||||
@section('page-scripts')
|
|
||||||
@js('/site/js/bootstrap3-typeahead.min.js','bs-typeahead')
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
|
||||||
$(document).ready(function() {
|
|
||||||
$("input[name=q]").typeahead({
|
|
||||||
delay: 300,
|
|
||||||
minLength: 2,
|
|
||||||
fitToElement: false,
|
|
||||||
appendTo: "#search_results",
|
|
||||||
source: function (query,process) {
|
|
||||||
search('{{ url("search",['date'=>isset($ido) ? $ido->id : NULL]) }}',query,process);
|
|
||||||
},
|
|
||||||
|
|
||||||
matcher: function () { return true; },
|
|
||||||
|
|
||||||
updater: function (item) {
|
|
||||||
window.parent.location.href = '{{ url("/") }}'+users[item];
|
|
||||||
},
|
|
||||||
})
|
|
||||||
.on('keyup keypress', function(event) {
|
|
||||||
var key = event.keyCode || event.which;
|
|
||||||
if (key === 13) {
|
|
||||||
event.preventDefault();
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
var c=0;
|
|
||||||
var search = _.debounce(function(url,query,process,icon){
|
|
||||||
$.ajax({
|
|
||||||
url : url,
|
|
||||||
type : 'GET',
|
|
||||||
data : 'term=' + query,
|
|
||||||
dataType : 'JSON',
|
|
||||||
async : false,
|
|
||||||
cache : false,
|
|
||||||
beforeSend : function() {
|
|
||||||
if (c++ == 0) {
|
|
||||||
if (icon)
|
|
||||||
$('i[name='+icon+']').addClass("fa-spin");
|
|
||||||
else
|
|
||||||
$('i[name=searching]').removeClass("hidden");
|
|
||||||
}
|
|
||||||
},
|
|
||||||
success : function(data) {
|
|
||||||
// if json is null, means no match, won't do again.
|
|
||||||
if(data==null || (data.length===0)) return;
|
|
||||||
|
|
||||||
users = {};
|
|
||||||
userLabels = [];
|
|
||||||
_.each(data,function(item,ix,list) {
|
|
||||||
if (_.includes(users,item.label))
|
|
||||||
item.label = item.label + ' #' + item.value;
|
|
||||||
|
|
||||||
userLabels.push(item.label);
|
|
||||||
users[item.label] = item.value;
|
|
||||||
});
|
|
||||||
|
|
||||||
process(userLabels);
|
|
||||||
},
|
|
||||||
complete : function() {
|
|
||||||
if (--c == 0) {
|
|
||||||
if (icon)
|
|
||||||
$('i[name='+icon+']').removeClass("fa-spin");
|
|
||||||
else
|
|
||||||
$('i[name=searching]').addClass("hidden");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}, 500);
|
|
||||||
</script>
|
|
||||||
@append
|
|
||||||
|
@@ -1,5 +1,11 @@
|
|||||||
<ul class="sidebar-menu" data-widget="tree">
|
<li class="nav-header">MAIN</li>
|
||||||
<li class="header"><b>MENU</b></li>
|
|
||||||
<!-- Optionally, you can add icons to the links -->
|
<li class="nav-item">
|
||||||
<li @if(Route::current()->getName() == 'home')class="active"@endif><a href="{{ url('home',['date'=>(isset($ido) ? $ido->id : NULL)]) }}"><i class='fa fa-link'></i> <span>{{ trans('adminlte_lang::message.home') }}</span></a></li>
|
<a href="#" class="nav-link @if(Route::current()->getName() == 'home') active @endif">
|
||||||
</ul>
|
<i class="nav-icon fa fa-th"></i>
|
||||||
|
<p>
|
||||||
|
My Link Title
|
||||||
|
<span class="right badge badge-danger">New</span>
|
||||||
|
</p>
|
||||||
|
</a>
|
||||||
|
</li>
|
@@ -0,0 +1,7 @@
|
|||||||
|
{{--
|
||||||
|
@foreach ($topmenu as $url => $title)
|
||||||
|
<li class="nav-item d-none d-sm-inline-block">
|
||||||
|
<a href="{{ $url }}" class="nav-link">{{ $title }}</a>
|
||||||
|
</li>
|
||||||
|
@endforeach
|
||||||
|
--}}
|
29
src/GuestUser.php
Normal file
29
src/GuestUser.php
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Leenooks;
|
||||||
|
|
||||||
|
use Illuminate\Notifications\Notifiable;
|
||||||
|
use Illuminate\Foundation\Auth\User as Authenticatable;
|
||||||
|
|
||||||
|
class GuestUser extends Authenticatable
|
||||||
|
{
|
||||||
|
use Notifiable;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The attributes that are mass assignable.
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
protected $fillable = [
|
||||||
|
'name', 'email', 'password',
|
||||||
|
];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The attributes that should be hidden for arrays.
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
protected $hidden = [
|
||||||
|
'password', 'remember_token',
|
||||||
|
];
|
||||||
|
}
|
27
src/Http/Middleware/GuestUser.php
Normal file
27
src/Http/Middleware/GuestUser.php
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Leenooks\Http\Middleware;
|
||||||
|
|
||||||
|
use Closure;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Class GuestUser
|
||||||
|
* @package Leenooks\Laravel\Http\Middleware
|
||||||
|
*/
|
||||||
|
class GuestUser
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Handle an incoming request.
|
||||||
|
*
|
||||||
|
* @param \Illuminate\Http\Request $request
|
||||||
|
* @param \Closure $next
|
||||||
|
* @return mixed
|
||||||
|
*/
|
||||||
|
public function handle($request, Closure $next)
|
||||||
|
{
|
||||||
|
view()->share('loggedin',auth()->check());
|
||||||
|
view()->share('user', auth()->user() ?: new \Leenooks\GuestUser);
|
||||||
|
|
||||||
|
return $next($request);
|
||||||
|
}
|
||||||
|
}
|
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
namespace Leenooks\Providers;
|
namespace Leenooks\Providers;
|
||||||
|
|
||||||
|
use Leenooks\Http\Middleware\GuestUser;
|
||||||
use Illuminate\Routing\Router;
|
use Illuminate\Routing\Router;
|
||||||
use Illuminate\Support\ServiceProvider;
|
use Illuminate\Support\ServiceProvider;
|
||||||
|
|
||||||
@@ -21,12 +22,15 @@ class LeenooksServiceProvider extends ServiceProvider
|
|||||||
*/
|
*/
|
||||||
public function boot(Router $router)
|
public function boot(Router $router)
|
||||||
{
|
{
|
||||||
|
$router->pushMiddlewareToGroup('web',GuestUser::class);
|
||||||
|
|
||||||
$this->loadViewsFrom($this->_path.'/resources/themes/adminlte/views/', 'adminlte');
|
$this->loadViewsFrom($this->_path.'/resources/themes/adminlte/views/', 'adminlte');
|
||||||
$this->loadTranslationsFrom($this->_path.'/resources/themes/adminlte/lang/', 'adminlte_lang');
|
$this->loadTranslationsFrom($this->_path.'/resources/themes/adminlte/lang/', 'adminlte_lang');
|
||||||
|
|
||||||
// Enable a recusive() collection function so that we can just arrives in config/*.php
|
// Enable a Collect::recursive() function
|
||||||
\Illuminate\Support\Collection::macro('recursive', function () {
|
\Illuminate\Support\Collection::macro('recursive', function () {
|
||||||
return $this->map(function ($value) {
|
return $this->map(function ($value) {
|
||||||
|
|
||||||
if (is_array($value) || is_object($value)) {
|
if (is_array($value) || is_object($value)) {
|
||||||
return collect($value)->recursive();
|
return collect($value)->recursive();
|
||||||
}
|
}
|
||||||
@@ -56,16 +60,11 @@ class LeenooksServiceProvider extends ServiceProvider
|
|||||||
public function views()
|
public function views()
|
||||||
{
|
{
|
||||||
return [
|
return [
|
||||||
$this->_path.'/resources/views/auth' =>
|
$this->_path.'/resources/views/auth' => resource_path('views/vendor/adminlte/auth'),
|
||||||
resource_path('views/vendor/adminlte/auth'),
|
$this->_path.'/resources/views/errors' => resource_path('views/vendor/adminlte/errors'),
|
||||||
$this->_path.'/resources/views/errors' =>
|
$this->_path.'/resources/views/layouts' => resource_path('views/vendor/adminlte/layouts'),
|
||||||
resource_path('views/vendor/adminlte/errors'),
|
$this->_path.'/resources/views/home.blade.php' => resource_path('views/vendor/adminlte/home.blade.php'),
|
||||||
$this->_path.'/resources/views/layouts' =>
|
$this->_path.'/resources/views/welcome.blade.php' => resource_path('views/welcome.blade.php'),
|
||||||
resource_path('views/vendor/adminlte/layouts'),
|
|
||||||
$this->_path.'/resources/views/home.blade.php' =>
|
|
||||||
resource_path('views/vendor/adminlte/home.blade.php'),
|
|
||||||
$this->_path.'/resources/views/welcome.blade.php' =>
|
|
||||||
resource_path('views/welcome.blade.php'),
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
}
|
}
|
Reference in New Issue
Block a user