Merge pull request #4417 from atm-arnaud/3.8_fix_factures_nblignes_after_hook

FIX nblignes not calculated after hook and hook can't modify this val...
This commit is contained in:
Laurent Destailleur 2016-01-22 02:10:36 +01:00
commit 219ce73ea2

View File

@ -250,6 +250,9 @@ class pdf_crabe extends ModelePDFFactures
global $action;
$reshook=$hookmanager->executeHooks('beforePDFCreation',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
// Set nblignes with the new facture lines content after hook
$nblignes = count($object->lines);
// Create pdf instance
$pdf=pdf_getInstance($this->format);
$default_font_size = pdf_getPDFFontSize($outputlangs); // Must be after pdf_getInstance