1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 13:12:50 +01:00

Merge pull request #6395 from turbo124/v5-develop

Minor fixes for live preview
This commit is contained in:
David Bomba 2021-08-05 20:03:33 +10:00 committed by GitHub
commit f2d3c88094
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -200,13 +200,13 @@ class PreviewController extends BaseController
if($request->has('entity_id')){
$entity_obj = $class::on(auth()->user()->company()->db)
->withTrashed()
->where('id', $this->decodePrimaryKey($request->input('entity_id')))
->where('company_id', auth()->user()->company()->id)
->first();
// $entity_obj = $class::on(auth()->user()->company()->db)
// ->withTrashed()
// ->where('id', $this->decodePrimaryKey($request->input('entity_id')))
// ->where('company_id', auth()->user()->company()->id)
// ->first();
$entity_obj = $repo->save($request->all(), $entity_obj);
$entity_obj = $repo->save($request->all(), $factory);
}
else {