Add API routes and expand v2 frontend

This commit is contained in:
James Cole
2023-09-20 06:18:25 +02:00
parent 0e3ebb9f1a
commit 6b5774a66d
8 changed files with 69 additions and 48 deletions

View File

@@ -202,6 +202,24 @@ Route::group(
}
);
/**
* V2 API route for user groups (administrations).
*/
Route::group(
[
'namespace' => 'FireflyIII\Api\V2\Controllers\UserGroup',
'prefix' => 'v2/user-groups',
'as' => 'api.v2.user-groups.',
],
static function () {
Route::get('', ['uses' => 'ShowController@index', 'as' => 'index']);
Route::post('', ['uses' => 'StoreController@store', 'as' => 'store']);
Route::get('{userGroup}', ['uses' => 'ShowController@show', 'as' => 'show']);
}
);
// down here is v1
/**
* Autocomplete controllers
*/