mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-19 06:43:45 +02:00
Initial moves to new API scheme.
Implements a better middleware for handling API authentication, as well as cleaner route handling.
This commit is contained in:
@@ -33,6 +33,14 @@ class RouteServiceProvider extends ServiceProvider
|
||||
*/
|
||||
public function map()
|
||||
{
|
||||
Route::middleware(['api'])->prefix('/api/user')
|
||||
->namespace($this->namespace . '\API\User')
|
||||
->group(base_path('routes/api.php'));
|
||||
|
||||
Route::middleware(['api'])->prefix('/api/admin')
|
||||
->namespace($this->namespace . '\API\Admin')
|
||||
->group(base_path('routes/api-admin.php'));
|
||||
|
||||
Route::middleware(['web', 'auth', 'csrf'])
|
||||
->namespace($this->namespace . '\Base')
|
||||
->group(base_path('routes/base.php'));
|
||||
|
||||
Reference in New Issue
Block a user