Redirect /dashboard/login directly to Nextcloud OAuth via web route
Deploy / deploy (push) Successful in 16s
Deploy / deploy (push) Successful in 16s
Overriding mount() conflicts with parent void return type; intercepting the URL in routes/web.php (registered before Filament) is the clean fix. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
f53ea6a823
commit
c3a3cabc2c
2 files changed
+4
-2
No files matched your search
@@ -6,8 +6,8 @@ use Filament\Pages\Auth\Login as BaseLogin;
|
|||||||
|
|
||||||
class Login extends BaseLogin
|
class Login extends BaseLogin
|
||||||
{
|
{
|
||||||
public function mount()
|
public function getView(): string
|
||||||
{
|
{
|
||||||
return redirect()->route('auth.nextcloud');
|
return 'filament.pages.auth.login';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -7,5 +7,7 @@ Route::get('/', function () {
|
|||||||
return redirect('/dashboard', 301);
|
return redirect('/dashboard', 301);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Route::get('/dashboard/login', fn () => redirect()->route('auth.nextcloud'));
|
||||||
|
|
||||||
Route::get('/oauth/redirect', [OAuthController::class, 'redirect'])->name('auth.nextcloud');
|
Route::get('/oauth/redirect', [OAuthController::class, 'redirect'])->name('auth.nextcloud');
|
||||||
Route::get('/auth/nextcloud/callback', [OAuthController::class, 'callback'])->name('auth.nextcloud.callback');
|
Route::get('/auth/nextcloud/callback', [OAuthController::class, 'callback'])->name('auth.nextcloud.callback');
|
||||||
Reference in new issue
Block a user