First round of changes to API to support simpler permissions.
This commit is contained in:
parent
0e24c669c4
commit
a31e5875dc
21 changed files with 403 additions and 169 deletions
|
@ -1,5 +1,7 @@
|
|||
<?php
|
||||
|
||||
use Pterodactyl\Models\User;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| User Controller Routes
|
||||
|
@ -9,6 +11,10 @@
|
|||
|
|
||||
*/
|
||||
Route::group(['prefix' => '/users'], function () {
|
||||
Route::bind('user', function ($value) {
|
||||
return User::find($value) ?? new User;
|
||||
});
|
||||
|
||||
Route::get('/', 'Users\UserController@index')->name('api.admin.user.list');
|
||||
Route::get('/{user}', 'Users\UserController@view')->name('api.admin.user.view');
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue