mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-03 00:34:35 -04:00
Added ability to set arguments sent to Snappdf
This commit is contained in:
parent
74d47b1464
commit
a0520f38d0
@ -241,6 +241,11 @@ class SetupController extends Controller
|
|||||||
$pdf->setChromiumPath(config('ninja.snappdf_chromium_path'));
|
$pdf->setChromiumPath(config('ninja.snappdf_chromium_path'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (config('ninja.snappdf_chromium_arguments')) {
|
||||||
|
$pdf->clearChromiumArguments();
|
||||||
|
$pdf->addChromiumArguments(config('ninja.snappdf_chromium_arguments'));
|
||||||
|
}
|
||||||
|
|
||||||
$pdf = $pdf
|
$pdf = $pdf
|
||||||
->setHtml('GENERATING PDFs WORKS! Thank you for using Invoice Ninja!')
|
->setHtml('GENERATING PDFs WORKS! Thank you for using Invoice Ninja!')
|
||||||
->generate();
|
->generate();
|
||||||
|
@ -34,6 +34,11 @@ trait PdfMaker
|
|||||||
$pdf->setChromiumPath(config('ninja.snappdf_chromium_path'));
|
$pdf->setChromiumPath(config('ninja.snappdf_chromium_path'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (config('ninja.snappdf_chromium_arguments')) {
|
||||||
|
$pdf->clearChromiumArguments();
|
||||||
|
$pdf->addChromiumArguments(config('ninja.snappdf_chromium_arguments'));
|
||||||
|
}
|
||||||
|
|
||||||
$generated = $pdf
|
$generated = $pdf
|
||||||
->setHtml($html)
|
->setHtml($html)
|
||||||
->generate();
|
->generate();
|
||||||
|
@ -142,6 +142,7 @@ return [
|
|||||||
'log_pdf_html' => env('LOG_PDF_HTML', false),
|
'log_pdf_html' => env('LOG_PDF_HTML', false),
|
||||||
'expanded_logging' => env('EXPANDED_LOGGING', false),
|
'expanded_logging' => env('EXPANDED_LOGGING', false),
|
||||||
'snappdf_chromium_path' => env('SNAPPDF_CHROMIUM_PATH', false),
|
'snappdf_chromium_path' => env('SNAPPDF_CHROMIUM_PATH', false),
|
||||||
|
'snappdf_chromium_arguments' => env('SNAPPDF_CHROMIUM_ARGUMENTS', false),
|
||||||
'v4_migration_version' => '4.5.35',
|
'v4_migration_version' => '4.5.35',
|
||||||
'flutter_renderer' => env('FLUTTER_RENDERER', 'selfhosted-html'),
|
'flutter_renderer' => env('FLUTTER_RENDERER', 'selfhosted-html'),
|
||||||
'webcron_secret' => env('WEBCRON_SECRET', false),
|
'webcron_secret' => env('WEBCRON_SECRET', false),
|
||||||
|
@ -34,6 +34,11 @@ class PdfGenerationTest extends TestCase
|
|||||||
$pdf->setChromiumPath(config('ninja.snappdf_chromium_path'));
|
$pdf->setChromiumPath(config('ninja.snappdf_chromium_path'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (config('ninja.snappdf_chromium_arguments')) {
|
||||||
|
$pdf->clearChromiumArguments();
|
||||||
|
$pdf->addChromiumArguments(config('ninja.snappdf_chromium_arguments'));
|
||||||
|
}
|
||||||
|
|
||||||
$pdf = $pdf
|
$pdf = $pdf
|
||||||
->setHtml('<h1>Invoice Ninja</h1>')
|
->setHtml('<h1>Invoice Ninja</h1>')
|
||||||
->generate();
|
->generate();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user