24 lines
884 B
PHP
24 lines
884 B
PHP
<?php
|
|
|
|
use Illuminate\Support\Facades\Route;
|
|
|
|
Route::get('/', fn() => redirect('/dashboard'));
|
|
|
|
// Test route for middleware test — only reachable with school-admin or teacher role
|
|
Route::middleware(['auth', 'role:school-admin,teacher'])->group(function () {
|
|
Route::get('/school/dashboard', fn() => response('ok'))->name('school.dashboard');
|
|
});
|
|
|
|
Route::get('/dashboard', fn() => view('dashboard'))->name('dashboard')->middleware(['auth', 'license']);
|
|
|
|
Route::get('/lizenz-abgelaufen', fn() => view('lizenz-abgelaufen'))->name('lizenz.abgelaufen');
|
|
|
|
Route::view('profile', 'profile')->middleware(['auth'])->name('profile');
|
|
|
|
require __DIR__.'/auth.php';
|
|
|
|
// Quick-Login: double-defense (isLocal + ALLOW_QUICK_LOGIN env)
|
|
if (app()->isLocal() && env('ALLOW_QUICK_LOGIN', false)) {
|
|
Route::get('/dev/quick-login', \App\Livewire\DevQuickLogin::class)->name('dev.quick-login');
|
|
}
|