Feature #9 : Add Auth Layout
This commit is contained in:
parent
4ac79cdf9d
commit
e6f1bb4815
@ -1,6 +1,8 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
use Modules\Usermanagement\Models\User;
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -62,7 +64,7 @@ return [
|
||||
'providers' => [
|
||||
'users' => [
|
||||
'driver' => 'eloquent',
|
||||
'model' => env('AUTH_MODEL', App\Models\User::class),
|
||||
'model' => env('AUTH_MODEL', User::class),
|
||||
],
|
||||
|
||||
// 'users' => [
|
||||
|
13
resources/views/layouts/auth.blade.php
Normal file
13
resources/views/layouts/auth.blade.php
Normal file
@ -0,0 +1,13 @@
|
||||
@php
|
||||
use Illuminate\Support\Facades\Route;
|
||||
|
||||
$route = explode('.',Route::currentRouteName());
|
||||
$modules = file_get_contents(dirname(__FILE__, 4) . '/modules_statuses.json');
|
||||
$module = json_decode($modules);
|
||||
@endphp
|
||||
|
||||
@extends('layouts.base', ['module' => $module])
|
||||
|
||||
@section('main')
|
||||
@yield('content')
|
||||
@endsection
|
@ -11,6 +11,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" type="image/x-icon" href="favicon.ico">
|
||||
@vite('resources/css/app.scss')
|
||||
@stack('styles')
|
||||
</head>
|
||||
|
||||
<body class="flex h-full metronic sidebar-fixed header-fixed bg-[#fefefe] dark:bg-coal-500">
|
||||
|
@ -1346,7 +1346,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="menu-item px-4 py-1.5">
|
||||
<a class="btn btn-sm btn-light justify-center" href="html/demo1/authentication/classic/sign-in.html">
|
||||
<a class="btn btn-sm btn-light justify-center" href="{{ route('logout') }}">
|
||||
Log out
|
||||
</a>
|
||||
</div>
|
||||
|
@ -1,7 +1,9 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Route;
|
||||
Route::middleware(['auth'])->group(function () {
|
||||
Route::get('/', function () {
|
||||
return view('welcome');
|
||||
})->name('dashboard');
|
||||
|
||||
Route::get('/', function () {
|
||||
return view('welcome');
|
||||
});
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user