diff --git a/app/Http/Controllers/CheckInOutRequest.php b/app/Http/Controllers/CheckInOutRequest.php index 328553eb49..6ab327fff8 100644 --- a/app/Http/Controllers/CheckInOutRequest.php +++ b/app/Http/Controllers/CheckInOutRequest.php @@ -20,7 +20,7 @@ trait CheckInOutRequest return Location::findOrFail(request('assigned_location')); case 'asset': return Asset::findOrFail(request('assigned_asset')); - case 'user': + default: return User::findOrFail(request('assigned_user')); } diff --git a/resources/views/accessories/checkout.blade.php b/resources/views/accessories/checkout.blade.php index 0fe6abec36..9ad87f018e 100755 --- a/resources/views/accessories/checkout.blade.php +++ b/resources/views/accessories/checkout.blade.php @@ -66,14 +66,8 @@ - @include ('partials.forms.checkout-selector', ['user_select' => 'true','asset_select' => 'true', 'location_select' => 'true']) - @include ('partials.forms.edit.user-select', ['translated_name' => trans('general.select_user'), 'fieldname' => 'assigned_user', 'required'=> 'true']) - - @include ('partials.forms.edit.asset-select', ['translated_name' => trans('general.asset'), 'fieldname' => 'assigned_asset', 'unselect' => 'true', 'style' => 'display:none;', 'required'=>'true']) - - @include ('partials.forms.edit.location-select', ['translated_name' => trans('general.location'), 'fieldname' => 'assigned_location', 'style' => 'display:none;', 'required'=>'true'])