mirror of
https://github.com/snipe/snipe-it.git
synced 2025-03-05 20:52:15 -08:00
fix all
This commit is contained in:
parent
27a7c6fd10
commit
d949a9689f
|
@ -71,12 +71,12 @@ class AssetFilesController extends Controller
|
|||
try {
|
||||
return StorageHelper::showOrDownloadFile($file, $log->filename);
|
||||
} catch (\Exception $e) {
|
||||
return redirect()->route('hardware.show', ['hardware' => $asset])->with('error', trans('general.file_not_found'));
|
||||
return redirect()->route('hardware.show', $asset)->with('error', trans('general.file_not_found'));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return redirect()->route('hardware.show', ['hardware' => $asset])->with('error', trans('general.log_record_not_found'));
|
||||
return redirect()->route('hardware.show', $asset)->with('error', trans('general.log_record_not_found'));
|
||||
|
||||
|
||||
}
|
||||
|
@ -102,7 +102,7 @@ class AssetFilesController extends Controller
|
|||
return redirect()->back()->withFragment('files')->with('success', trans('admin/hardware/message.deletefile.success'));
|
||||
}
|
||||
|
||||
return redirect()->route('hardware.show', ['hardware' => $asset])->with('error', trans('general.log_record_not_found'));
|
||||
return redirect()->route('hardware.show', $asset)->with('error', trans('general.log_record_not_found'));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -141,7 +141,7 @@ class Label implements View
|
|||
break;
|
||||
case 'hardware_id':
|
||||
default:
|
||||
$barcode2DTarget = route('hardware.show', ['hardware' => $asset->id]);
|
||||
$barcode2DTarget = route('hardware.show', $asset);
|
||||
break;
|
||||
}
|
||||
$assetData->put('barcode2d', (object)[
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
@php
|
||||
$checkin = Helper::getFormattedDateObject($asset->expected_checkin, 'date');
|
||||
@endphp
|
||||
| [{{ $asset->present()->name }}]({{ route('hardware.show', ['asset' => $asset]) }}) | [{{ $asset->assignedTo->present()->fullName }}]({{ route($asset->targetShowRoute().'.show', [$asset->assignedTo->id]) }}) | {{ $checkin['formatted'] }}
|
||||
| [{{ $asset->present()->name }}]({{ route('hardware.show', $asset) }}) | [{{ $asset->assignedTo->present()->fullName }}]({{ route($asset->targetShowRoute().'.show', [$asset->assignedTo->id]) }}) | {{ $checkin['formatted'] }}
|
||||
@endforeach
|
||||
@endcomponent
|
||||
|
||||
|
|
|
@ -126,7 +126,7 @@ Route::group(
|
|||
|
||||
// Redirect old legacy /asset_id/view urls to the resource route version
|
||||
Route::get('{assetId}/view', function ($assetId) {
|
||||
return redirect()->route('hardware.show', ['hardware' => $assetId]);
|
||||
return redirect()->route('hardware.show', $assetId);
|
||||
});
|
||||
|
||||
Route::get('{asset}/qr_code',
|
||||
|
|
Loading…
Reference in a new issue