mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-10 07:34:06 -08:00
Merge pull request #13655 from snipe/bug/sc-23759
Fixed bug where checkout to location would throw an error if FMCS was enabled
This commit is contained in:
commit
1509339b68
|
@ -91,7 +91,8 @@ class AssetCheckoutController extends Controller
|
|||
|
||||
$settings = \App\Models\Setting::getSettings();
|
||||
|
||||
if ($settings->full_multiple_companies_support){
|
||||
// We have to check whether $target->company_id is null here since locations don't have a company yet
|
||||
if (($settings->full_multiple_companies_support) && ((!is_null($target->company_id)) && (!is_null($asset->company_id)))) {
|
||||
if ($target->company_id != $asset->company_id){
|
||||
return redirect()->to("hardware/$assetId/checkout")->with('error', trans('general.error_user_company'));
|
||||
}
|
||||
|
|
|
@ -459,7 +459,7 @@ return [
|
|||
'serial_number' => 'Serial Number',
|
||||
'item_notes' => ':item Notes',
|
||||
'item_name_var' => ':item Name',
|
||||
'error_user_company' => 'User and Asset companies missmatch',
|
||||
'error_user_company' => 'Checkout target company and asset company do not match',
|
||||
'error_user_company_accept_view' => 'An Asset assigned to you belongs to a different company so you can\'t accept nor deny it, please check with your manager',
|
||||
'importer' => [
|
||||
'checked_out_to_fullname' => 'Checked Out to: Full Name',
|
||||
|
|
Loading…
Reference in a new issue