diff --git a/htdocs/core/modules/rapport/pdf_paiement.class.php b/htdocs/core/modules/rapport/pdf_paiement.class.php index 35ffc399372..54f0e418eb0 100644 --- a/htdocs/core/modules/rapport/pdf_paiement.class.php +++ b/htdocs/core/modules/rapport/pdf_paiement.class.php @@ -122,6 +122,8 @@ class pdf_paiement $month = sprintf("%02d",$month); $year = sprintf("%04d",$year); + + $file = $dir . "/payments-".$year."-".$month.".pdf"; switch ($this->doc_type) { case "client": $file = $dir . "/payments-".$year."-".$month.".pdf"; @@ -251,7 +253,7 @@ class pdf_paiement while ($i < $num) { $objp = $this->db->fetch_object($result); - + $lines[$i][0] = $objp->facnumber; $lines[$i][1] = dol_print_date($this->db->jdate($objp->dp),"day",false,$outputlangs,true); @@ -328,9 +330,9 @@ class pdf_paiement if (! empty($conf->global->MAIN_UMASK)) @chmod($file, octdec($conf->global->MAIN_UMASK)); - + $this->result = array('fullpath'=>$file); - + return 1; }