Add inline disposition for PDF previews
This commit is contained in:
parent
f5f447a3ff
commit
2bf0326797
|
|
@ -131,7 +131,7 @@ class InvoiceController extends Controller
|
||||||
|
|
||||||
$file = (new \App\Jobs\Entity\CreateRawPdf($invitation))->handle();
|
$file = (new \App\Jobs\Entity\CreateRawPdf($invitation))->handle();
|
||||||
|
|
||||||
$headers = ['Content-Type' => 'application/pdf'];
|
$headers = ['Content-Type' => 'application/pdf', 'Content-Disposition' => 'inline'];
|
||||||
return response()->make($file, 200, $headers);
|
return response()->make($file, 200, $headers);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -124,7 +124,8 @@ class PurchaseOrderController extends Controller
|
||||||
|
|
||||||
$file = $invitation->purchase_order->service()->getPurchaseOrderPdf();
|
$file = $invitation->purchase_order->service()->getPurchaseOrderPdf();
|
||||||
|
|
||||||
$headers = ['Content-Type' => 'application/pdf'];
|
// $headers = ['Content-Type' => 'application/pdf'];
|
||||||
|
$headers = ['Content-Type' => 'application/pdf', 'Content-Disposition' => 'inline'];
|
||||||
|
|
||||||
return response()->make($file, 200, $headers);
|
return response()->make($file, 200, $headers);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue