mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-05 00:34:35 -04:00
Fixes for preview
This commit is contained in:
parent
55c7c23475
commit
9a55743e3b
@ -200,7 +200,7 @@ class PreviewController extends BaseController
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
DB::connection($company->db)->beginTransaction();
|
DB::connection(config('database.default'))->beginTransaction();
|
||||||
|
|
||||||
if($request->has('entity_id')){
|
if($request->has('entity_id')){
|
||||||
|
|
||||||
@ -267,7 +267,7 @@ class PreviewController extends BaseController
|
|||||||
->design($template)
|
->design($template)
|
||||||
->build();
|
->build();
|
||||||
|
|
||||||
DB::connection($company->db)->rollBack();
|
DB::connection(config('database.default'))->rollBack();
|
||||||
|
|
||||||
if (request()->query('html') == 'true') {
|
if (request()->query('html') == 'true') {
|
||||||
return $maker->getCompiledHTML;
|
return $maker->getCompiledHTML;
|
||||||
@ -277,7 +277,7 @@ class PreviewController extends BaseController
|
|||||||
}
|
}
|
||||||
catch(\Exception $e){
|
catch(\Exception $e){
|
||||||
|
|
||||||
DB::connection($company->db)->rollBack();
|
DB::connection(config('database.default'))->rollBack();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user