Better middleware for routes, cleaned up API, removed old API calls

New API routes for Server allow specifying which fractal objects to
load into the request, thus making it possible to fine-tune what data
is returned.
This commit is contained in:
Dane Everitt
2017-04-02 13:19:39 -04:00
parent ddb82ac3ca
commit 97773300ed
15 changed files with 304 additions and 747 deletions

View File

@@ -32,7 +32,10 @@ Route::get('/', 'CoreController@index')->name('api.user');
| Endpoint: /api/user/server/{server}
|
*/
Route::group(['prefix' => '/server/{server}'], function () {
Route::group([
'prefix' => '/server/{server}',
'middleware' => 'server',
], function () {
Route::get('/', 'ServerController@index')->name('api.user.server');
Route::post('/power', 'ServerController@power')->name('api.user.server.power');