mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-26 22:19:41 -08:00
aa8f1378c9
Signed-off-by: snipe <snipe@snipe.net> # Conflicts: # README.md # app/Http/Controllers/Accessories/AccessoriesController.php # app/Http/Controllers/Api/AssetMaintenancesController.php # app/Http/Controllers/Api/AssetModelsController.php # app/Http/Controllers/Api/AssetsController.php # app/Http/Controllers/Api/UsersController.php # app/Http/Controllers/AssetMaintenancesController.php # app/Http/Controllers/Assets/AssetFilesController.php # app/Http/Controllers/Assets/AssetsController.php # app/Http/Controllers/Assets/BulkAssetsController.php # app/Http/Controllers/Components/ComponentsController.php # app/Http/Controllers/Consumables/ConsumablesController.php # app/Http/Controllers/Licenses/LicenseFilesController.php # app/Http/Controllers/Licenses/LicensesController.php # app/Http/Controllers/Users/UserFilesController.php # app/Http/Transformers/AssetsTransformer.php # app/Http/Transformers/LicensesTransformer.php # app/Importer/UserImporter.php # app/Models/Asset.php # config/app.php # config/version.php # package-lock.json # public/js/build/app.js # public/js/dist/all.js # public/js/dist/bootstrap-table.js # public/mix-manifest.json # resources/lang/en/admin/users/message.php # resources/lang/is/button.php # resources/lang/ja/admin/kits/general.php # resources/lang/ro/admin/users/general.php # resources/lang/zh-HK/admin/depreciations/general.php # resources/lang/zh-HK/admin/models/general.php # resources/views/hardware/qr-view.blade.php # resources/views/hardware/view.blade.php # resources/views/partials/bootstrap-table.blade.php # resources/views/users/view.blade.php # routes/web.php # routes/web/hardware.php # routes/web/models.php # routes/web/users.php
83 lines
1.7 KiB
PHP
83 lines
1.7 KiB
PHP
<?php
|
|
|
|
use App\Http\Controllers\AssetModelsController;
|
|
use App\Http\Controllers\BulkAssetModelsController;
|
|
use Illuminate\Support\Facades\Route;
|
|
|
|
// Asset Model Management
|
|
|
|
|
|
Route::group(['prefix' => 'models', 'middleware' => ['auth']], function () {
|
|
|
|
Route::get(
|
|
'{modelId}/clone',
|
|
[
|
|
AssetModelsController::class,
|
|
'getClone'
|
|
]
|
|
)->name('clone/model');
|
|
|
|
Route::post(
|
|
'{modelId}/clone',
|
|
[
|
|
AssetModelsController::class,
|
|
'postCreate'
|
|
]
|
|
)->name('clone/model');
|
|
|
|
Route::get(
|
|
'{modelId}/view',
|
|
[
|
|
AssetModelsController::class,
|
|
'getView'
|
|
]
|
|
)->name('view/model');
|
|
|
|
Route::post(
|
|
'{modelID}/restore',
|
|
[
|
|
AssetModelsController::class,
|
|
'getRestore'
|
|
]
|
|
)->name('restore/model');
|
|
|
|
Route::get(
|
|
'{modelId}/custom_fields',
|
|
[
|
|
AssetModelsController::class,
|
|
'getCustomFields'
|
|
]
|
|
)->name('custom_fields/model');
|
|
|
|
Route::post(
|
|
'bulkedit',
|
|
[
|
|
BulkAssetModelsController::class,
|
|
'edit'
|
|
]
|
|
)->name('models.bulkedit.index');
|
|
|
|
Route::post(
|
|
'bulksave',
|
|
[
|
|
BulkAssetModelsController::class,
|
|
'update'
|
|
]
|
|
)->name('models.bulkedit.store');
|
|
|
|
Route::post(
|
|
'bulkdelete',
|
|
[
|
|
BulkAssetModelsController::class,
|
|
'destroy'
|
|
]
|
|
)->name('models.bulkdelete.store');
|
|
|
|
|
|
});
|
|
|
|
Route::resource('models', AssetModelsController::class, [
|
|
'middleware' => ['auth'],
|
|
'parameters' => ['model' => 'model_id'],
|
|
]);
|