cleanup: simplify QR language selection
This commit is contained in:
parent
408b958226
commit
eafde2ad7e
|
|
@ -961,14 +961,8 @@ class pdf_swissqr extends ModelePDFFactures
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Define the translation to use
|
$qrLang = in_array($langs->shortlang, ['de', 'fr', 'it']) ? $langs->shortlang : 'en';
|
||||||
if ($langs->shortlang == 'de' || $langs->shortlang == 'fr' || $langs->shortlang == 'it' || $langs->shortlang == 'en')
|
$output = new QrBill\PaymentPart\Output\TcPdfOutput\TcPdfOutput($qrBill, $qrLang, $pdf);
|
||||||
{
|
|
||||||
$output = new QrBill\PaymentPart\Output\TcPdfOutput\TcPdfOutput($qrBill, $langs->shortlang, $pdf);
|
|
||||||
} else
|
|
||||||
{
|
|
||||||
$output = new QrBill\PaymentPart\Output\TcPdfOutput\TcPdfOutput($qrBill, 'en', $pdf);
|
|
||||||
}
|
|
||||||
|
|
||||||
$output->setPrintable(false)->getPaymentPart();
|
$output->setPrintable(false)->getPaymentPart();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue