mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
commit
0dc8bb1fb2
@ -270,6 +270,7 @@ class PreviewController extends BaseController
|
|||||||
DB::connection(config('database.default'))->rollBack();
|
DB::connection(config('database.default'))->rollBack();
|
||||||
|
|
||||||
if (request()->query('html') == 'true') {
|
if (request()->query('html') == 'true') {
|
||||||
|
DB::purge(config('database.default'));
|
||||||
return $maker->getCompiledHTML;
|
return $maker->getCompiledHTML;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -278,6 +279,8 @@ class PreviewController extends BaseController
|
|||||||
catch(\Exception $e){
|
catch(\Exception $e){
|
||||||
|
|
||||||
DB::connection(config('database.default'))->rollBack();
|
DB::connection(config('database.default'))->rollBack();
|
||||||
|
DB::purge(config('database.default'));
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -301,6 +304,7 @@ class PreviewController extends BaseController
|
|||||||
->batch();
|
->batch();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DB::purge(config('database.default'));
|
||||||
|
|
||||||
$response = Response::make($file_path, 200);
|
$response = Response::make($file_path, 200);
|
||||||
$response->header('Content-Type', 'application/pdf');
|
$response->header('Content-Type', 'application/pdf');
|
||||||
|
Loading…
x
Reference in New Issue
Block a user