snipe-it/routes/web/components.php

34 lines
966 B
PHP
Raw Normal View History

2016-12-15 19:59:42 -08:00
<?php
2021-06-10 13:17:14 -07:00
use App\Http\Controllers\Components;
use Illuminate\Support\Facades\Route;
// Components
Route::group(['prefix' => 'components', 'middleware' => ['auth']], function () {
2016-12-15 19:59:42 -08:00
Route::get(
'{componentID}/checkout',
[Components\ComponentCheckoutController::class, 'create']
)->name('checkout/accessory');
2016-12-15 19:59:42 -08:00
Route::post(
'{componentID}/checkout',
[Components\ComponentCheckoutController::class, 'store']
)->name('checkout/accessory');
2017-11-08 06:06:05 -08:00
Route::get(
'{componentID}/checkin/{backto?}',
[Components\ComponentCheckinController::class, 'create']
)->name('checkout/accessory');
2017-11-08 06:06:05 -08:00
Route::post(
'{componentID}/checkin/{backto?}',
[Components\ComponentCheckinController::class, 'store']
)->name('checkout/accessory');
2016-12-15 19:59:42 -08:00
});
2021-06-10 13:17:14 -07:00
Route::resource('components', Components\ComponentsController::class, [
'middleware' => ['auth'],
'parameters' => ['component' => 'component_id'],
2016-12-15 19:59:42 -08:00
]);