mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-09 23:24:06 -08:00
Departments routes
This commit is contained in:
parent
0c43e64160
commit
e3a5accace
|
@ -79,6 +79,24 @@ Route::group(['prefix' => 'v1','namespace' => 'Api'], function () {
|
|||
); // Companies resource
|
||||
|
||||
|
||||
/*--- Departments API ---*/
|
||||
|
||||
Route::resource('departments', 'DepartmentsController',
|
||||
[
|
||||
'names' =>
|
||||
[
|
||||
'index' => 'api.departments.index',
|
||||
'show' => 'api.departments.show',
|
||||
'store' => 'api.departments.store',
|
||||
'update' => 'api.departments.update',
|
||||
'destroy' => 'api.departments.destroy'
|
||||
],
|
||||
'except' => ['create', 'edit'],
|
||||
'parameters' => ['department' => 'department_id']
|
||||
]
|
||||
); // Departments resource
|
||||
|
||||
|
||||
/*--- Components API ---*/
|
||||
|
||||
Route::resource('components', 'ComponentsController',
|
||||
|
|
104
routes/web.php
104
routes/web.php
|
@ -2,62 +2,70 @@
|
|||
|
||||
|
||||
Route::group(['middleware' => 'auth'], function () {
|
||||
/*
|
||||
* Companies
|
||||
*/
|
||||
Route::resource('companies', 'CompaniesController', [
|
||||
'parameters' => ['company' => 'company_id']
|
||||
]);
|
||||
/*
|
||||
* Companies
|
||||
*/
|
||||
Route::resource('companies', 'CompaniesController', [
|
||||
'parameters' => ['company' => 'company_id']
|
||||
]);
|
||||
|
||||
/*
|
||||
* Categories
|
||||
*/
|
||||
Route::resource('categories', 'CategoriesController', [
|
||||
'parameters' => ['category' => 'category_id']
|
||||
]);
|
||||
/*
|
||||
* Categories
|
||||
*/
|
||||
Route::resource('categories', 'CategoriesController', [
|
||||
'parameters' => ['category' => 'category_id']
|
||||
]);
|
||||
|
||||
/*
|
||||
* Locations
|
||||
*/
|
||||
Route::resource('locations', 'LocationsController', [
|
||||
'parameters' => ['location' => 'location_id']
|
||||
]);
|
||||
/*
|
||||
* Locations
|
||||
*/
|
||||
Route::resource('locations', 'LocationsController', [
|
||||
'parameters' => ['location' => 'location_id']
|
||||
]);
|
||||
|
||||
/*
|
||||
* Manufacturers
|
||||
*/
|
||||
Route::resource('manufacturers', 'ManufacturersController', [
|
||||
'parameters' => ['manufacturer' => 'manufacturers_id']
|
||||
]);
|
||||
/*
|
||||
* Manufacturers
|
||||
*/
|
||||
Route::resource('manufacturers', 'ManufacturersController', [
|
||||
'parameters' => ['manufacturer' => 'manufacturers_id']
|
||||
]);
|
||||
|
||||
/*
|
||||
* Suppliers
|
||||
*/
|
||||
Route::resource('suppliers', 'SuppliersController', [
|
||||
'parameters' => ['supplier' => 'supplier_id']
|
||||
]);
|
||||
/*
|
||||
* Suppliers
|
||||
*/
|
||||
Route::resource('suppliers', 'SuppliersController', [
|
||||
'parameters' => ['supplier' => 'supplier_id']
|
||||
]);
|
||||
|
||||
/*
|
||||
* Depreciations
|
||||
*/
|
||||
Route::resource('depreciations', 'DepreciationsController', [
|
||||
'parameters' => ['depreciation' => 'depreciation_id']
|
||||
]);
|
||||
/*
|
||||
* Depreciations
|
||||
*/
|
||||
Route::resource('depreciations', 'DepreciationsController', [
|
||||
'parameters' => ['depreciation' => 'depreciation_id']
|
||||
]);
|
||||
|
||||
/*
|
||||
* Status Labels
|
||||
*/
|
||||
Route::resource('statuslabels', 'StatuslabelsController', [
|
||||
'parameters' => ['statuslabel' => 'statuslabel_id']
|
||||
]);
|
||||
/*
|
||||
* Status Labels
|
||||
*/
|
||||
Route::resource('statuslabels', 'StatuslabelsController', [
|
||||
'parameters' => ['statuslabel' => 'statuslabel_id']
|
||||
]);
|
||||
|
||||
|
||||
/*
|
||||
* Status Labels
|
||||
*/
|
||||
Route::resource('components', 'ComponentsController', [
|
||||
'parameters' => ['component' => 'component_id']
|
||||
]);
|
||||
/*
|
||||
* Status Labels
|
||||
*/
|
||||
Route::resource('components', 'ComponentsController', [
|
||||
'parameters' => ['component' => 'component_id']
|
||||
]);
|
||||
|
||||
/*
|
||||
* Departments
|
||||
*/
|
||||
Route::resource('departments', 'DepartmentsController', [
|
||||
'parameters' => ['department' => 'department_id']
|
||||
]);
|
||||
|
||||
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue