Added strings, variables to the controllers

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe
2023-02-23 11:41:19 -08:00
parent 7851e7c0b0
commit c284d8d436
6 changed files with 20 additions and 14 deletions
@@ -851,11 +851,11 @@ class AssetsController extends Controller
$asset->next_audit_date = $request->input('next_audit_date');
$asset->last_audit_date = date('Y-m-d H:i:s');
$asset->audit_type = $request->input('audit_type', 'physical');
// Check to see if they checked the box to update the physical location,
// not just note it in the audit notes
if ($request->input('update_location') == '1') {
\Log::debug('update location in audit');
$asset->location_id = $request->input('location_id');
}
@@ -874,8 +874,7 @@ class AssetsController extends Controller
Storage::putFileAs($path, $upload, $file_name);
}
$asset->logAudit($request->input('note'), $request->input('location_id'), $file_name);
$asset->logAudit($request->input('note'), $request->input('location_id'), $file_name, $request->input('audit_type'));
return redirect()->route('assets.audit.due')->with('success', trans('admin/hardware/message.audit.success'));
}
}