mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-28 06:59:41 -08:00
30 lines
1,001 B
PHP
30 lines
1,001 B
PHP
<?php
|
|
|
|
use App\Http\Controllers\Components;
|
|
use Illuminate\Support\Facades\Route;
|
|
|
|
// Components
|
|
Route::group(['prefix' => 'components', 'middleware' => ['auth']], function () {
|
|
Route::get(
|
|
'{componentID}/checkout',
|
|
['as' => 'checkout/component', 'uses' => [Components\ComponentCheckoutController::class, 'create']]
|
|
);
|
|
Route::post(
|
|
'{componentID}/checkout',
|
|
['as' => 'checkout/component', 'uses' => [Components\ComponentCheckoutController::class, 'store']]
|
|
);
|
|
Route::get(
|
|
'{componentID}/checkin',
|
|
['as' => 'checkin/component', 'uses' => [Components\ComponentCheckinController::class, 'create']]
|
|
);
|
|
Route::post(
|
|
'{componentID}/checkin',
|
|
['as' => 'component.checkin.save', 'uses' => [Components\ComponentCheckinController::class, 'store']]
|
|
);
|
|
});
|
|
|
|
Route::resource('components', Components\ComponentsController::class, [
|
|
'middleware' => ['auth'],
|
|
'parameters' => ['component' => 'component_id'],
|
|
]);
|