Update pdf_sponge.modules.php

Does not display linked objects if the new PDF option is checked
This commit is contained in:
nat 2024-12-09 21:00:25 +01:00 committed by GitHub
parent 6004c64905
commit 7a842dc104
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2445,10 +2445,12 @@ class pdf_sponge extends ModelePDFFactures
$top_shift = 0;
$shipp_shift = 0;
// Show list of linked objects
$current_y = $pdf->getY();
$posy = pdf_writeLinkedObjects($pdf, $object, $outputlangs, $posx, $posy, $w, 3, 'R', $default_font_size);
if ($current_y < $pdf->getY()) {
$top_shift = $pdf->getY() - $current_y;
if (!getDolGlobalString('INVOICE_HIDE_LINKED_OBJECT')) {
$current_y = $pdf->getY();
$posy = pdf_writeLinkedObjects($pdf, $object, $outputlangs, $posx, $posy, $w, 3, 'R', $default_font_size);
if ($current_y < $pdf->getY()) {
$top_shift = $pdf->getY() - $current_y;
}
}
if ($showaddress) {