Fix: Bad CR for public note. Must work when text is full text with \n
and also when text is HTML with br.
This commit is contained in:
parent
91b8f33ea5
commit
907c7f748d
@ -235,7 +235,7 @@ class pdf_einstein extends ModelePDFCommandes
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to manage multipages
|
$pdf->SetFont('','', $default_font_size - 1); // Into loop to manage multipages
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
@ -309,7 +309,7 @@ class pdf_einstein extends ModelePDFCommandes
|
|||||||
if ($object->remise_percent) $tvaligne-=($tvaligne*$object->remise_percent)/100;
|
if ($object->remise_percent) $tvaligne-=($tvaligne*$object->remise_percent)/100;
|
||||||
if ($object->remise_percent) $localtax1ligne-=($localtax1ligne*$object->remise_percent)/100;
|
if ($object->remise_percent) $localtax1ligne-=($localtax1ligne*$object->remise_percent)/100;
|
||||||
if ($object->remise_percent) $localtax2ligne-=($localtax2ligne*$object->remise_percent)/100;
|
if ($object->remise_percent) $localtax2ligne-=($localtax2ligne*$object->remise_percent)/100;
|
||||||
|
|
||||||
$vatrate=(string) $object->lines[$i]->tva_tx;
|
$vatrate=(string) $object->lines[$i]->tva_tx;
|
||||||
$localtax1rate=(string) $object->lines[$i]->localtax1_tx;
|
$localtax1rate=(string) $object->lines[$i]->localtax1_tx;
|
||||||
$localtax2rate=(string) $object->lines[$i]->localtax2_tx;
|
$localtax2rate=(string) $object->lines[$i]->localtax2_tx;
|
||||||
|
|||||||
@ -195,7 +195,7 @@ Class pdf_expedition_rouget extends ModelePdfExpedition
|
|||||||
if (! empty($object->note_public))
|
if (! empty($object->note_public))
|
||||||
{
|
{
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
|
|||||||
@ -235,7 +235,7 @@ class pdf_crabe extends ModelePDFFactures
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1);
|
$pdf->SetFont('','', $default_font_size - 1);
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
|
|||||||
@ -185,7 +185,7 @@ class pdf_soleil extends ModelePDFFicheinter
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
|
|||||||
@ -213,7 +213,7 @@ class pdf_typhon extends ModelePDFDeliveryOrder
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
|
|||||||
@ -173,7 +173,7 @@ class pdf_baleine extends ModelePDFProjects
|
|||||||
if (! empty($object->note_public))
|
if (! empty($object->note_public))
|
||||||
{
|
{
|
||||||
$pdf->SetFont('','', $default_font_size - 1);
|
$pdf->SetFont('','', $default_font_size - 1);
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxref-1, $tab_top-2, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxref-1, $tab_top-2, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-($tab_top-2);
|
$height_note=$nexY-($tab_top-2);
|
||||||
|
|
||||||
|
|||||||
@ -222,7 +222,7 @@ class pdf_azur extends ModelePDFPropales
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
||||||
$pdf->writeHTMLCell(190, 4, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 4, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
|
|||||||
@ -222,7 +222,7 @@ class pdf_jaune extends ModelePDFPropales
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
||||||
$pdf->writeHTMLCell(190, 4, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 4, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
|
|||||||
@ -228,7 +228,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
|
|||||||
@ -241,7 +241,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
|||||||
$tab_top = 88;
|
$tab_top = 88;
|
||||||
|
|
||||||
$pdf->SetFont('','', $default_font_size - 1); // Into loop to manage multipages
|
$pdf->SetFont('','', $default_font_size - 1); // Into loop to manage multipages
|
||||||
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, $outputlangs->convToOutputCharset($object->note_public), 0, 1);
|
$pdf->writeHTMLCell(190, 3, $this->posxdesc-1, $tab_top, dol_htmlentitiesbr($object->note_public), 0, 1);
|
||||||
$nexY = $pdf->GetY();
|
$nexY = $pdf->GetY();
|
||||||
$height_note=$nexY-$tab_top;
|
$height_note=$nexY-$tab_top;
|
||||||
|
|
||||||
@ -1008,7 +1008,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
|||||||
{
|
{
|
||||||
$carac_client_name=$outputlangs->convToOutputCharset($object->client->name);
|
$carac_client_name=$outputlangs->convToOutputCharset($object->client->name);
|
||||||
}
|
}
|
||||||
|
|
||||||
$carac_client=pdf_build_address($outputlangs,$this->emetteur,$object->client,$object->contact,$usecontact,'target');
|
$carac_client=pdf_build_address($outputlangs,$this->emetteur,$object->client,$object->contact,$usecontact,'target');
|
||||||
|
|
||||||
// Show recipient
|
// Show recipient
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user