diff --git a/htdocs/core/modules/contract/doc/pdf_strato.modules.php b/htdocs/core/modules/contract/doc/pdf_strato.modules.php index 2dc2acbcb6d..24dcf8743b0 100644 --- a/htdocs/core/modules/contract/doc/pdf_strato.modules.php +++ b/htdocs/core/modules/contract/doc/pdf_strato.modules.php @@ -370,7 +370,7 @@ class pdf_strato extends ModelePDFContract $pdf->writeHTMLCell(0, 0, $curX, $curY, dol_concatdesc($txtpredefinedservice, dol_concatdesc($txt, $desc)), 0, 1, 0); $pageposafter=$pdf->getPage(); $posyafter=$pdf->GetY(); - + if ($posyafter > ($this->page_hauteur - ($heightforfooter+$heightforfreetext+$heightforinfotot))) // There is no space left for total+free text { if ($i == ($nblines-1)) // No more lines, and no space left to show total, so we create a new page @@ -394,7 +394,7 @@ class pdf_strato extends ModelePDFContract $nexY = $pdf->GetY() + 2; $pageposafter=$pdf->getPage(); - + $pdf->setPage($pageposbefore); $pdf->setTopMargin($this->marge_haute); $pdf->setPageOrientation('', 1, 0); // The only function to edit the bottom margin of current page to set it. @@ -423,7 +423,7 @@ class pdf_strato extends ModelePDFContract $pdf->setPage($pagenb); $pdf->setPageOrientation('', 1, 0); // The only function to edit the bottom margin of current page to set it. } - + if (isset($object->lines[$i+1]->pagebreak) && $object->lines[$i+1]->pagebreak) { if ($pagenb == 1) @@ -447,7 +447,7 @@ class pdf_strato extends ModelePDFContract if ($pagenb == 1) { $this->_tableau($pdf, $tab_top, $this->page_hauteur - $tab_top - $heightforinfotot - $heightforfreetext - $heightforfooter, 0, $outputlangs, 0, 0); - $this->_tab_signature($pdf, $tab_top, $this->page_hauteur - $tab_top - $heightforinfotot - $heightforfreetext - $heightforfooter, $outputlangs); + $this->tabSignature($pdf, $tab_top, $this->page_hauteur - $tab_top - $heightforinfotot - $heightforfreetext - $heightforfooter, $outputlangs); $bottomlasttab=$this->page_hauteur - $heightforfooter - $heightforfooter + 1; } else @@ -456,7 +456,7 @@ class pdf_strato extends ModelePDFContract $this->tabSignature($pdf, $tab_top_newpage, $this->page_hauteur - $tab_top_newpage - $heightforinfotot - $heightforfreetext - $heightforfooter, $outputlangs); $bottomlasttab=$this->page_hauteur - $heightforfooter - $heightforfooter + 1; } - + $this->_pagefoot($pdf,$object,$outputlangs); if (method_exists($pdf,'AliasNbPages')) $pdf->AliasNbPages();