diff --git a/app/Http/Controllers/ClientPortal/InvoiceController.php b/app/Http/Controllers/ClientPortal/InvoiceController.php
index 9746863da046..ff5a0d493650 100644
--- a/app/Http/Controllers/ClientPortal/InvoiceController.php
+++ b/app/Http/Controllers/ClientPortal/InvoiceController.php
@@ -57,7 +57,7 @@ class InvoiceController extends Controller
];
if ($request->query('mode') === 'fullscreen') {
- return response()->file($invoice->pdf_file_path(null, 'path'));
+ return render('invoices.show-fullscreen', $data);
}
return $this->render('invoices.show', $data);
diff --git a/app/Http/Controllers/ClientPortal/QuoteController.php b/app/Http/Controllers/ClientPortal/QuoteController.php
index e634cdb258e8..a7d6354eeecc 100644
--- a/app/Http/Controllers/ClientPortal/QuoteController.php
+++ b/app/Http/Controllers/ClientPortal/QuoteController.php
@@ -44,7 +44,7 @@ class QuoteController extends Controller
];
if ($request->query('mode') === 'fullscreen') {
- return response()->file($quote->pdf_file_path(null, 'path'));
+ return render('quotes.show-fullscreen', $data);
}
return $this->render('quotes.show', $data);
@@ -76,9 +76,9 @@ class QuoteController extends Controller
}
if ($quotes->count() == 1) {
- return response()->streamDownload(function () use ($invoices) {
- echo file_get_contents($invoices->first()->pdf_file_path());
- }, basename($invoices->first()->pdf_file_path()), ['Cache-Control:' => 'no-cache']);
+ return response()->streamDownload(function () use ($quotes) {
+ echo file_get_contents($quotes->first()->pdf_file_path());
+ }, basename($quotes->first()->pdf_file_path()), ['Cache-Control:' => 'no-cache']);
//return response()->download(TempFile::path($invoices->first()->pdf_file_path()), basename($quotes->first()->pdf_file_path()));
}
diff --git a/resources/views/portal/ninja2020/invoices/show-fullscreen.blade.php b/resources/views/portal/ninja2020/invoices/show-fullscreen.blade.php
new file mode 100644
index 000000000000..8b1bb3b8da23
--- /dev/null
+++ b/resources/views/portal/ninja2020/invoices/show-fullscreen.blade.php
@@ -0,0 +1,2 @@
+
diff --git a/resources/views/portal/ninja2020/quotes/show-fullscreen.blade.php b/resources/views/portal/ninja2020/quotes/show-fullscreen.blade.php
new file mode 100644
index 000000000000..0c1d9597545e
--- /dev/null
+++ b/resources/views/portal/ninja2020/quotes/show-fullscreen.blade.php
@@ -0,0 +1,2 @@
+