2
0
forked from Wavyzz/dolibarr

Fix: Space before opening parenthesis of function call prohibited

This commit is contained in:
Regis Houssin
2011-09-20 12:56:06 +00:00
parent e8cd289ac0
commit 6c4acefd93
45 changed files with 479 additions and 479 deletions

View File

@@ -249,24 +249,24 @@ class BordereauChequeBlochet extends ModeleChequeReceipts
$pdf->MultiCell(40, 2, $langs->trans("Total"));
$pdf->SetFont('','B', $default_font_size);
$pdf->SetXY (170, $posy+1);
$pdf->SetXY(170, $posy+1);
$pdf->MultiCell(31, 2, price($this->amount), 0, 'C', 0);
// Tableau
$pdf->SetFont('','', $default_font_size - 2);
$pdf->SetXY (11, $this->tab_top+2);
$pdf->SetXY(11, $this->tab_top+2);
$pdf->MultiCell(40,2,$outputlangs->transnoentities("Num"), 0, 'L');
$pdf->line(40, $this->tab_top, 40, $this->tab_top + $this->tab_height + 10);
$pdf->SetXY (41, $this->tab_top+2);
$pdf->SetXY(41, $this->tab_top+2);
$pdf->MultiCell(40,2,$outputlangs->transnoentities("Bank"), 0, 'L');
$pdf->line(100, $this->tab_top, 100, $this->tab_top + $this->tab_height + 10);
$pdf->SetXY (101, $this->tab_top+2);
$pdf->SetXY(101, $this->tab_top+2);
$pdf->MultiCell(40,2,$outputlangs->transnoentities("CheckTransmitter"), 0, 'L');
$pdf->line(180, $this->tab_top, 180, $this->tab_top + $this->tab_height + 10);
$pdf->SetXY (180, $this->tab_top+2);
$pdf->SetXY(180, $this->tab_top+2);
$pdf->MultiCell(20,2,$outputlangs->transnoentities("Amount"), 0, 'R');
$pdf->line(9, $this->tab_top + 8, 201, $this->tab_top + 8);
@@ -293,19 +293,19 @@ class BordereauChequeBlochet extends ModeleChequeReceipts
{
$lineinpage++;
$pdf->SetXY (1, $this->tab_top + 10 + $yp);
$pdf->SetXY(1, $this->tab_top + 10 + $yp);
$pdf->MultiCell(8, $this->line_height, $j+1, 0, 'R', 0);
$pdf->SetXY (10, $this->tab_top + 10 + $yp);
$pdf->SetXY(10, $this->tab_top + 10 + $yp);
$pdf->MultiCell(30, $this->line_height, $this->lines[$j]->num_chq?$this->lines[$j]->num_chq:'', 0, 'L', 0);
$pdf->SetXY (40, $this->tab_top + 10 + $yp);
$pdf->SetXY(40, $this->tab_top + 10 + $yp);
$pdf->MultiCell(70, $this->line_height, dol_trunc($outputlangs->convToOutputCharset($this->lines[$j]->bank_chq),44), 0, 'L', 0);
$pdf->SetXY (100, $this->tab_top + 10 + $yp);
$pdf->SetXY(100, $this->tab_top + 10 + $yp);
$pdf->MultiCell(80, $this->line_height, dol_trunc($outputlangs->convToOutputCharset($this->lines[$j]->emetteur_chq),50), 0, 'L', 0);
$pdf->SetXY (180, $this->tab_top + 10 + $yp);
$pdf->SetXY(180, $this->tab_top + 10 + $yp);
$pdf->MultiCell(20, $this->line_height, price($this->lines[$j]->amount_chq), 0, 'R', 0);
$yp = $yp + $this->line_height;

View File

@@ -181,7 +181,7 @@ class pdf_edison extends ModelePDFCommandes
$pdf->SetTextColor(0,0,0);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY (10, $tab_top + 10 );
$pdf->SetXY(10, $tab_top + 10 );
$iniY = $pdf->GetY();
$curY = $pdf->GetY();
@@ -201,23 +201,23 @@ class pdf_edison extends ModelePDFCommandes
$nexY = $pdf->GetY();
$ref = pdf_getlineref($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY (10, $curY);
$pdf->SetXY(10, $curY);
$pdf->MultiCell(20, 3, $ref, 0, 'C');
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY (133, $curY);
$pdf->SetXY(133, $curY);
$pdf->MultiCell(12, 3, $vat_rate, 0, 'C');
$qty = pdf_getlineqty($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY (145, $curY);
$pdf->SetXY(145, $curY);
$pdf->MultiCell(10, 3, $qty, 0, 'C');
$up_excl_tax = pdf_getlineupexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY (156, $curY);
$pdf->SetXY(156, $curY);
$pdf->MultiCell(18, 3, $up_excl_tax, 0, 'R', 0);
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY (174, $curY);
$pdf->SetXY(174, $curY);
$pdf->MultiCell(26, 3, $total_excl_tax, 0, 'R', 0);
$nexY+=2; // Passe espace entre les lignes
@@ -264,22 +264,22 @@ class pdf_edison extends ModelePDFCommandes
$pdf->SetFont('','', $default_font_size);
$pdf->SetXY (132, $tab2_top + 0);
$pdf->SetXY(132, $tab2_top + 0);
$pdf->MultiCell(42, $tab2_lh, $langs->transnoentities("TotalHT"), 0, 'R', 0);
$pdf->SetXY (132, $tab2_top + $tab2_lh);
$pdf->SetXY(132, $tab2_top + $tab2_lh);
$pdf->MultiCell(42, $tab2_lh, $langs->transnoentities("TotalVAT"), 0, 'R', 0);
$pdf->SetXY (132, $tab2_top + ($tab2_lh*2));
$pdf->SetXY(132, $tab2_top + ($tab2_lh*2));
$pdf->MultiCell(42, $tab2_lh, $langs->transnoentities("TotalTTC"), 1, 'R', 1);
$pdf->SetXY (174, $tab2_top + 0);
$pdf->SetXY(174, $tab2_top + 0);
$pdf->MultiCell(26, $tab2_lh, price($object->total_ht), 0, 'R', 0);
$pdf->SetXY (174, $tab2_top + $tab2_lh);
$pdf->SetXY(174, $tab2_top + $tab2_lh);
$pdf->MultiCell(26, $tab2_lh, price($object->total_tva), 0, 'R', 0);
$pdf->SetXY (174, $tab2_top + ($tab2_lh*2));
$pdf->SetXY(174, $tab2_top + ($tab2_lh*2));
$pdf->MultiCell(26, $tab2_lh, price($object->total_ttc), 1, 'R', 1);
// Pied de page

View File

@@ -228,7 +228,7 @@ class pdf_einstein extends ModelePDFCommandes
$tab_top = 88;
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-$tab_top;
@@ -267,22 +267,22 @@ class pdf_einstein extends ModelePDFCommandes
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxtva, $curY);
$pdf->SetXY($this->posxtva, $curY);
$pdf->MultiCell($this->posxup-$this->posxtva-1, 3, $vat_rate, 0, 'R');
}
// Prix unitaire HT avant remise
$up_excl_tax = pdf_getlineupexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxup, $curY);
$pdf->SetXY($this->posxup, $curY);
$pdf->MultiCell($this->posxqty-$this->posxup-1, 3, $up_excl_tax, 0, 'R', 0);
// Quantity
$qty = pdf_getlineqty($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxqty, $curY);
$pdf->SetXY($this->posxqty, $curY);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1, 3, $qty, 0, 'R');
// Remise sur ligne
$pdf->SetXY ($this->posxdiscount, $curY);
$pdf->SetXY($this->posxdiscount, $curY);
if ($object->lines[$i]->remise_percent)
{
$remise_percent = pdf_getlineremisepercent($object, $i, $outputlangs, $hidedetails, $hookmanager);
@@ -291,7 +291,7 @@ class pdf_einstein extends ModelePDFCommandes
// Total HT ligne
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->postotalht, $curY);
$pdf->SetXY($this->postotalht, $curY);
$pdf->MultiCell(26, 3, $total_excl_tax, 0, 'R', 0);
// Collecte des totaux par valeur de tva dans $this->tva["taux"]=total_tva
@@ -592,10 +592,10 @@ class pdf_einstein extends ModelePDFCommandes
// Total HT
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + 0);
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + 0);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + $object->remise), 0, 'R', 1);
// Show VAT by rates and total
@@ -611,7 +611,7 @@ class pdf_einstein extends ModelePDFCommandes
$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -623,26 +623,26 @@ class pdf_einstein extends ModelePDFCommandes
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
if (! $this->atleastoneratenotnull) // If not vat at all
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalVAT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_tva), 0, 'R', 1);
// Total LocalTax1
if (! empty($conf->global->FACTURE_LOCAL_TAX1_OPTION) && $conf->global->FACTURE_LOCAL_TAX1_OPTION=='localtax1on' && $object->total_localtax1>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT1".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax1), $useborder, 'R', 1);
}
@@ -650,9 +650,9 @@ class pdf_einstein extends ModelePDFCommandes
if (! empty($conf->global->FACTURE_LOCAL_TAX2_OPTION) && $conf->global->FACTURE_LOCAL_TAX2_OPTION=='localtax2on' && $object->total_localtax2>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT2".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax2), $useborder, 'R', 1);
}
}
@@ -668,7 +668,7 @@ class pdf_einstein extends ModelePDFCommandes
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -680,7 +680,7 @@ class pdf_einstein extends ModelePDFCommandes
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -696,7 +696,7 @@ class pdf_einstein extends ModelePDFCommandes
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -708,7 +708,7 @@ class pdf_einstein extends ModelePDFCommandes
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -720,12 +720,12 @@ class pdf_einstein extends ModelePDFCommandes
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
}
$pdf->SetTextColor(0,0,0);
@@ -735,9 +735,9 @@ class pdf_einstein extends ModelePDFCommandes
// Already paid + Deposits
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle), 0, 'R', 0);
$resteapayer = $object->total_ttc - $deja_regle;
@@ -746,10 +746,10 @@ class pdf_einstein extends ModelePDFCommandes
$index++;
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), $useborder, 'R', 1);
// Fin
@@ -786,28 +786,28 @@ class pdf_einstein extends ModelePDFCommandes
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+1);
$pdf->SetXY($this->posxdesc-1, $tab_top+1);
$pdf->MultiCell(108,2, $outputlangs->transnoentities("Designation"),'','L');
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$pdf->line($this->posxtva-1, $tab_top, $this->posxtva-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxtva-3, $tab_top+1);
$pdf->SetXY($this->posxtva-3, $tab_top+1);
$pdf->MultiCell($this->posxup-$this->posxtva+3,2, $outputlangs->transnoentities("VAT"),'','C');
}
$pdf->line($this->posxup-1, $tab_top, $this->posxup-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxup-1, $tab_top+1);
$pdf->SetXY($this->posxup-1, $tab_top+1);
$pdf->MultiCell($this->posxqty-$this->posxup-1,2, $outputlangs->transnoentities("PriceUHT"),'','C');
$pdf->line($this->posxqty-1, $tab_top, $this->posxqty-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqty-1, $tab_top+1);
$pdf->SetXY($this->posxqty-1, $tab_top+1);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1,2, $outputlangs->transnoentities("Qty"),'','C');
$pdf->line($this->posxdiscount-1, $tab_top, $this->posxdiscount-1, $tab_top + $tab_height);
if ($this->atleastonediscount)
{
$pdf->SetXY ($this->posxdiscount-1, $tab_top+1);
$pdf->SetXY($this->posxdiscount-1, $tab_top+1);
$pdf->MultiCell($this->postotalht-$this->posxdiscount+1,2, $outputlangs->transnoentities("ReductionShort"),'','C');
}
@@ -815,7 +815,7 @@ class pdf_einstein extends ModelePDFCommandes
{
$pdf->line($this->postotalht, $tab_top, $this->postotalht, $tab_top + $tab_height);
}
$pdf->SetXY ($this->postotalht-1, $tab_top+1);
$pdf->SetXY($this->postotalht-1, $tab_top+1);
$pdf->MultiCell(30,2, $outputlangs->transnoentities("TotalHT"),'','C');
}

View File

@@ -203,22 +203,22 @@ Class pdf_expedition_merou extends ModelePdfExpedition
$pdf->rect(10+3, $curY+1, 3, 3);
$pdf->rect(20+3, $curY+1, 3, 3);
//Insertion de la reference du produit
$pdf->SetXY (30, $curY+1 );
$pdf->SetXY(30, $curY+1 );
$pdf->SetFont('','B', $default_font_size - 3);
$pdf->MultiCell(24, 3, $outputlangs->convToOutputCharset($object->lines[$i]->ref), 0, 'L', 0);
//Insertion du libelle
$pdf->SetFont('','', $default_font_size - 3);
$pdf->SetXY (50, $curY+1 );
$pdf->SetXY(50, $curY+1 );
//$libelleproduitservice=pdf_getlinedesc($object->$origin,$i,$outputlangs);
$libelleproduitservice = pdf_writelinedesc($pdf,$object->$origin,$i,$outputlangs,90,3,50,$curY+1,1);
//$pdf->writeHTMLCell(90, 3, 50, $curY+1, $outputlangs->convToOutputCharset($libelleproduitservice), 0, 'L', 0);
//Insertion de la quantite commandee
$pdf->SetFont('','', $default_font_size - 3);
$pdf->SetXY (140, $curY+1 );
$pdf->SetXY(140, $curY+1 );
$pdf->MultiCell(30, 3, $object->lines[$i]->qty_asked, 0, 'C', 0);
//Insertion de la quantite a envoyer
$pdf->SetFont('','', $default_font_size - 3);
$pdf->SetXY (170, $curY+1 );
$pdf->SetXY(170, $curY+1 );
$pdf->MultiCell(30, 3, $object->lines[$i]->qty_shipped, 0, 'C', 0);
//Generation de la page 2

View File

@@ -186,7 +186,7 @@ Class pdf_expedition_rouget extends ModelePdfExpedition
if (! empty($object->note_public))
{
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
}
@@ -222,10 +222,10 @@ Class pdf_expedition_rouget extends ModelePdfExpedition
$pdf->SetFont('','', $default_font_size - 1); // On repositionne la police par defaut
$nexY = $pdf->GetY();
$pdf->SetXY ($this->posxqtyordered+5, $curY);
$pdf->SetXY($this->posxqtyordered+5, $curY);
$pdf->MultiCell(30, 3, $object->lines[$i]->qty_asked,'','C');
$pdf->SetXY ($this->posxqtytoship+5, $curY);
$pdf->SetXY($this->posxqtytoship+5, $curY);
$pdf->MultiCell(30, 3, $object->lines[$i]->qty_shipped,'','C');
$nexY+=2; // Passe espace entre les lignes
@@ -279,15 +279,15 @@ Class pdf_expedition_rouget extends ModelePdfExpedition
$pdf->SetFont('','',$default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+1);
$pdf->SetXY($this->posxdesc-1, $tab_top+1);
$pdf->MultiCell(108, 2, $outputlangs->trans("Description"), '', 'L');
$pdf->line($this->posxqtyordered-1, $tab_top, $this->posxqtyordered-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqtyordered-1, $tab_top+1);
$pdf->SetXY($this->posxqtyordered-1, $tab_top+1);
$pdf->MultiCell(40,2, $outputlangs->transnoentities("QtyOrdered"),'','C');
$pdf->line($this->posxqtytoship-1, $tab_top, $this->posxqtytoship-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqtytoship-1, $tab_top+1);
$pdf->SetXY($this->posxqtytoship-1, $tab_top+1);
$pdf->MultiCell(40,2, $outputlangs->transnoentities("QtyToShip"),'','C');
}

View File

@@ -229,7 +229,7 @@ class pdf_crabe extends ModelePDFFactures
$tab_top = 88;
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
//$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'J', false, 1, '', '', true, 0, false, false, 0, 'T', true);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'L'); // FPDF
$nexY = $pdf->GetY();
@@ -270,31 +270,31 @@ class pdf_crabe extends ModelePDFFactures
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxtva, $curY);
$pdf->SetXY($this->posxtva, $curY);
$pdf->MultiCell($this->posxup-$this->posxtva-1, 3, $vat_rate, 0, 'R');
}
// Prix unitaire HT avant remise
$up_excl_tax = pdf_getlineupexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxup, $curY);
$pdf->SetXY($this->posxup, $curY);
$pdf->MultiCell($this->posxqty-$this->posxup-1, 3, $up_excl_tax, 0, 'R', 0);
// Quantity
$qty = pdf_getlineqty($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxqty, $curY);
$pdf->SetXY($this->posxqty, $curY);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1, 3, $qty, 0, 'R'); // Enough for 6 chars
// Discount
if ($object->lines[$i]->remise_percent)
{
$pdf->SetXY ($this->posxdiscount-2, $curY);
$pdf->SetXY($this->posxdiscount-2, $curY);
$remise_percent = pdf_getlineremisepercent($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->MultiCell($this->postotalht-$this->posxdiscount+2, 3, $remise_percent, 0, 'R');
}
// Total HT ligne
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->postotalht, $curY);
$pdf->SetXY($this->postotalht, $curY);
$pdf->MultiCell(26, 3, $total_excl_tax, 0, 'R', 0);
// Collecte des totaux par valeur de tva dans $this->tva["taux"]=total_tva
@@ -443,19 +443,19 @@ class pdf_crabe extends ModelePDFFactures
$default_font_size = pdf_getPDFFontSize($outputlangs);
$pdf->SetFont('','', $default_font_size - 2);
$pdf->SetXY ($tab3_posx, $tab3_top - 5);
$pdf->SetXY($tab3_posx, $tab3_top - 5);
$pdf->MultiCell(60, 5, $outputlangs->transnoentities("PaymentsAlreadyDone"), 0, 'L', 0);
$pdf->line($tab3_posx, $tab3_top-1+$tab3_height, $tab3_posx+$tab3_width, $tab3_top-1+$tab3_height);
$pdf->SetFont('','', $default_font_size - 4);
$pdf->SetXY ($tab3_posx, $tab3_top );
$pdf->SetXY($tab3_posx, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Payment"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top );
$pdf->SetXY($tab3_posx+21, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Amount"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top );
$pdf->SetXY($tab3_posx+40, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Type"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top );
$pdf->SetXY($tab3_posx+58, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Num"), 0, 'L', 0);
$y=0;
@@ -485,13 +485,13 @@ class pdf_crabe extends ModelePDFFactures
$invoice->fetch($obj->fk_facture_source);
$pdf->SetXY ($tab3_posx, $tab3_top+$y );
$pdf->SetXY($tab3_posx, $tab3_top+$y );
$pdf->MultiCell(20, 3, dol_print_date($obj->datef,'day',false,$outputlangs,true), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top+$y);
$pdf->SetXY($tab3_posx+21, $tab3_top+$y);
$pdf->MultiCell(20, 3, price($obj->amount_ttc), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top+$y);
$pdf->SetXY($tab3_posx+40, $tab3_top+$y);
$pdf->MultiCell(20, 3, $text, 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top+$y);
$pdf->SetXY($tab3_posx+58, $tab3_top+$y);
$pdf->MultiCell(20, 3, $invoice->ref, 0, 'L', 0);
$pdf->line($tab3_posx, $tab3_top+$y+3, $tab3_posx+$tab3_width, $tab3_top+$y+3 );
@@ -522,15 +522,15 @@ class pdf_crabe extends ModelePDFFactures
$y+=3;
$row = $this->db->fetch_object($resql);
$pdf->SetXY ($tab3_posx, $tab3_top+$y );
$pdf->SetXY($tab3_posx, $tab3_top+$y );
$pdf->MultiCell(20, 3, dol_print_date($this->db->jdate($row->date),'day',false,$outputlangs,true), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top+$y);
$pdf->SetXY($tab3_posx+21, $tab3_top+$y);
$pdf->MultiCell(20, 3, price($row->amount), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top+$y);
$pdf->SetXY($tab3_posx+40, $tab3_top+$y);
$oper = $outputlangs->getTradFromKey("PaymentTypeShort" . $row->code);
$pdf->MultiCell(20, 3, $oper, 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top+$y);
$pdf->SetXY($tab3_posx+58, $tab3_top+$y);
$pdf->MultiCell(30, 3, $row->num, 0, 'L', 0);
$pdf->line($tab3_posx, $tab3_top+$y+3, $tab3_posx+$tab3_width, $tab3_top+$y+3 );
@@ -713,9 +713,9 @@ class pdf_crabe extends ModelePDFFactures
// Total HT
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + 0);
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + 0);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + $object->remise), 0, 'R', 1);
// Show VAT by rates and total
@@ -731,7 +731,7 @@ class pdf_crabe extends ModelePDFFactures
$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
{
@@ -741,7 +741,7 @@ class pdf_crabe extends ModelePDFFactures
$totalvat =$outputlangs->transnoentities("TotalVAT").' ';
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -749,18 +749,18 @@ class pdf_crabe extends ModelePDFFactures
if (! $this->atleastoneratenotnull) // If no vat at all
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalVAT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_tva), 0, 'R', 1);
// Total LocalTax1
if (! empty($conf->global->FACTURE_LOCAL_TAX1_OPTION) && $conf->global->FACTURE_LOCAL_TAX1_OPTION=='localtax1on' && $object->total_localtax1>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT1".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax1), $useborder, 'R', 1);
}
@@ -768,9 +768,9 @@ class pdf_crabe extends ModelePDFFactures
if (! empty($conf->global->FACTURE_LOCAL_TAX2_OPTION) && $conf->global->FACTURE_LOCAL_TAX2_OPTION=='localtax2on' && $object->total_localtax2>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT2".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax2), $useborder, 'R', 1);
}
}
@@ -786,7 +786,7 @@ class pdf_crabe extends ModelePDFFactures
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -798,7 +798,7 @@ class pdf_crabe extends ModelePDFFactures
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -814,7 +814,7 @@ class pdf_crabe extends ModelePDFFactures
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -826,7 +826,7 @@ class pdf_crabe extends ModelePDFFactures
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -838,13 +838,13 @@ class pdf_crabe extends ModelePDFFactures
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$text=$outputlangs->transnoentities("TotalTTC");
if ($object->type == 2) $text=$outputlangs->transnoentities("TotalTTCToYourCredit");
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $text, $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
}
$pdf->SetTextColor(0,0,0);
@@ -859,18 +859,18 @@ class pdf_crabe extends ModelePDFFactures
{
// Already paid + Deposits
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("Paid"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle + $depositsamount), 0, 'R', 0);
// Credit note
if ($creditnoteamount)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("CreditNotes"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($creditnoteamount), 0, 'R', 0);
}
@@ -880,9 +880,9 @@ class pdf_crabe extends ModelePDFFactures
$index++;
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("EscompteOffered"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle - $creditnoteamount - $depositsamount), $useborder, 'R', 1);
$resteapayer=0;
@@ -891,9 +891,9 @@ class pdf_crabe extends ModelePDFFactures
$index++;
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), $useborder, 'R', 1);
// Fin
@@ -932,28 +932,28 @@ class pdf_crabe extends ModelePDFFactures
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+1);
$pdf->SetXY($this->posxdesc-1, $tab_top+1);
$pdf->MultiCell(108,2, $outputlangs->transnoentities("Designation"),'','L');
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$pdf->line($this->posxtva-1, $tab_top, $this->posxtva-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxtva-3, $tab_top+1);
$pdf->SetXY($this->posxtva-3, $tab_top+1);
$pdf->MultiCell($this->posxup-$this->posxtva+3,2, $outputlangs->transnoentities("VAT"),'','C');
}
$pdf->line($this->posxup-1, $tab_top, $this->posxup-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxup-1, $tab_top+1);
$pdf->SetXY($this->posxup-1, $tab_top+1);
$pdf->MultiCell($this->posxqty-$this->posxup-1,2, $outputlangs->transnoentities("PriceUHT"),'','C');
$pdf->line($this->posxqty-1, $tab_top, $this->posxqty-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqty-1, $tab_top+1);
$pdf->SetXY($this->posxqty-1, $tab_top+1);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1,2, $outputlangs->transnoentities("Qty"),'','C');
$pdf->line($this->posxdiscount-1, $tab_top, $this->posxdiscount-1, $tab_top + $tab_height);
if ($this->atleastonediscount)
{
$pdf->SetXY ($this->posxdiscount-1, $tab_top+1);
$pdf->SetXY($this->posxdiscount-1, $tab_top+1);
$pdf->MultiCell($this->postotalht-$this->posxdiscount+1,2, $outputlangs->transnoentities("ReductionShort"),'','C');
}
@@ -961,7 +961,7 @@ class pdf_crabe extends ModelePDFFactures
{
$pdf->line($this->postotalht, $tab_top, $this->postotalht, $tab_top + $tab_height);
}
$pdf->SetXY ($this->postotalht-1, $tab_top+1);
$pdf->SetXY($this->postotalht-1, $tab_top+1);
$pdf->MultiCell(30,2, $outputlangs->transnoentities("TotalHT"),'','C');
}

View File

@@ -200,7 +200,7 @@ class pdf_oursin extends ModelePDFFactures
$pdf->SetFillColor(220,220,220);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->marges['g'], $tab_top + $this->marges['g'] );
$pdf->SetXY($this->marges['g'], $tab_top + $this->marges['g'] );
$iniY = $pdf->GetY();
$curY = $pdf->GetY();
@@ -223,23 +223,23 @@ class pdf_oursin extends ModelePDFFactures
if ($this->franchise!=1)
{
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->marges['g']+118, $curY);
$pdf->SetXY($this->marges['g']+118, $curY);
$pdf->MultiCell(12, 3, $vat_rate, 0, 'R');
}
}
// Prix unitaire HT avant remise
$up_excl_tax = pdf_getlineupexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->marges['g']+132, $curY);
$pdf->SetXY($this->marges['g']+132, $curY);
$pdf->MultiCell(16, 3, $up_excl_tax, 0, 'R', 0);
// Quantity
$qty = pdf_getlineqty($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->marges['g']+150, $curY);
$pdf->SetXY($this->marges['g']+150, $curY);
$pdf->MultiCell(10, 3, $qty, 0, 'R');
// Remise sur ligne
$pdf->SetXY ($this->marges['g']+160, $curY);
$pdf->SetXY($this->marges['g']+160, $curY);
if ($object->lines[$i]->remise_percent) {
$remise_percent = pdf_getlineremisepercent($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->MultiCell(14, 3, $remise_percent, 0, 'R');
@@ -247,7 +247,7 @@ class pdf_oursin extends ModelePDFFactures
// Total HT
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->marges['g']+168, $curY);
$pdf->SetXY($this->marges['g']+168, $curY);
$pdf->MultiCell(21, 3, $total_excl_tax, 0, 'R', 0);
@@ -327,19 +327,19 @@ class pdf_oursin extends ModelePDFFactures
$default_font_size = pdf_getPDFFontSize($outputlangs);
$pdf->SetFont('','', $default_font_size - 2);
$pdf->SetXY ($tab3_posx, $tab3_top - 5);
$pdf->SetXY($tab3_posx, $tab3_top - 5);
$pdf->MultiCell(60, 5, $outputlangs->transnoentities("PaymentsAlreadyDone"), 0, 'L', 0);
$pdf->Rect($tab3_posx, $tab3_top-1, $tab3_width, $tab3_height);
$pdf->SetFont('','', $default_font_size - 4);
$pdf->SetXY ($tab3_posx, $tab3_top-1 );
$pdf->SetXY($tab3_posx, $tab3_top-1 );
$pdf->MultiCell(20, 4, $outputlangs->transnoentities("Payment"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top-1 );
$pdf->SetXY($tab3_posx+21, $tab3_top-1 );
$pdf->MultiCell(20, 4, $outputlangs->transnoentities("Amount"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top-1 );
$pdf->SetXY($tab3_posx+40, $tab3_top-1 );
$pdf->MultiCell(20, 4, $outputlangs->transnoentities("Type"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top-1 );
$pdf->SetXY($tab3_posx+58, $tab3_top-1 );
$pdf->MultiCell(20, 4, $outputlangs->transnoentities("Num"), 0, 'L', 0);
$y=0;
@@ -369,13 +369,13 @@ class pdf_oursin extends ModelePDFFactures
$invoice->fetch($obj->fk_facture_source);
$pdf->SetXY ($tab3_posx, $tab3_top+$y );
$pdf->SetXY($tab3_posx, $tab3_top+$y );
$pdf->MultiCell(20, 3, dol_print_date($obj->datef,'day',false,$outputlangs,true), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top+$y);
$pdf->SetXY($tab3_posx+21, $tab3_top+$y);
$pdf->MultiCell(20, 3, price($obj->amount_ttc), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top+$y);
$pdf->SetXY($tab3_posx+40, $tab3_top+$y);
$pdf->MultiCell(20, 3, $text, 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top+$y);
$pdf->SetXY($tab3_posx+58, $tab3_top+$y);
$pdf->MultiCell(20, 3, $invoice->ref, 0, 'L', 0);
$pdf->line($tab3_posx, $tab3_top+$y+3, $tab3_posx+$tab3_width, $tab3_top+$y+3 );
@@ -406,15 +406,15 @@ class pdf_oursin extends ModelePDFFactures
$y+=3;
$row = $this->db->fetch_object($resql);
$pdf->SetXY ($tab3_posx, $tab3_top+$y );
$pdf->SetXY($tab3_posx, $tab3_top+$y );
$pdf->MultiCell(20, 3, dol_print_date($this->db->jdate($row->date),'day',false,$outputlangs,true), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top+$y);
$pdf->SetXY($tab3_posx+21, $tab3_top+$y);
$pdf->MultiCell(20, 3, price($row->amount), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top+$y);
$pdf->SetXY($tab3_posx+40, $tab3_top+$y);
$oper = $outputlangs->getTradFromKey("PaymentTypeShort" . $row->code);
$pdf->MultiCell(20, 3, $oper, 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top+$y);
$pdf->SetXY($tab3_posx+58, $tab3_top+$y);
$pdf->MultiCell(30, 3, $row->num, 0, 'L', 0);
$pdf->line($tab3_posx, $tab3_top+$y+3, $tab3_posx+$tab3_width, $tab3_top+$y+3 );
@@ -592,15 +592,15 @@ class pdf_oursin extends ModelePDFFactures
$col1x=$this->marges['g']+110; $col2x=$this->marges['g']+164;
$lltot = 200; $largcol2 = $lltot - $col2x;
$pdf->SetXY ($this->marges['g'], $tab2_top + 0);
$pdf->SetXY($this->marges['g'], $tab2_top + 0);
$useborder=0;
$index = 0;
// Total HT
$pdf->SetXY ($col1x, $tab2_top + 0);
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + 0);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + $object->remise), 0, 'R', 0);
// Show VAT by rates and total
@@ -616,7 +616,7 @@ class pdf_oursin extends ModelePDFFactures
$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
{
@@ -626,7 +626,7 @@ class pdf_oursin extends ModelePDFFactures
$totalvat =$outputlangs->transnoentities("TotalVAT").' ';
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -634,9 +634,9 @@ class pdf_oursin extends ModelePDFFactures
if (! $this->atleastoneratenotnull) // If no vat at all
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalVAT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_tva), 0, 'R', 1);
}
}
@@ -645,11 +645,11 @@ class pdf_oursin extends ModelePDFFactures
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetTextColor(22,137,210);
$pdf->SetFont('','B', $default_font_size + 1);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), 0, 'R', 0);
$pdf->SetTextColor(0,0,0);
}
@@ -665,18 +665,18 @@ class pdf_oursin extends ModelePDFFactures
// Already paid + Deposits
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle + $depositsamount), 0, 'R', 0);
// Credit note
if ($creditnoteamount)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("CreditNotes"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($creditnoteamount), 0, 'R', 0);
}
@@ -686,9 +686,9 @@ class pdf_oursin extends ModelePDFFactures
$index++;
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("EscompteOffered"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle - $creditnoteamount - $depositsamount), $useborder, 'R', 1);
$resteapayer=0;
@@ -696,10 +696,10 @@ class pdf_oursin extends ModelePDFFactures
$index++;
$pdf->SetTextColor(0,0,60);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), 0, 'L', 0);
$pdf->SetFillColor(224,224,224);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), 0, 'R', 0);
// Fin

View File

@@ -290,7 +290,7 @@ function facture_meta_create($db, $facid, $message="")
";
}
}
$fp = fopen ($file,"w");
$fp = fopen($file,"w");
fputs($fp,$meta);
fclose($fp);
if (! empty($conf->global->MAIN_UMASK))

View File

@@ -255,7 +255,7 @@ class pdf_soleil extends ModelePDFFicheinter
$tab_top = 98;
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($fichinter->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-$tab_top;

View File

@@ -184,23 +184,23 @@ class pdf_sirocco extends ModelePDFDeliveryOrder
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$nexY = $pdf->GetY();
$pdf->SetXY (10, $curY );
$pdf->SetXY(10, $curY );
$pdf->MultiCell(20, 3, $outputlangs->convToOutputCharset($object->lines[$i]->ref), 0, 'C');
// TODO Field not yet saved in database
//$pdf->SetXY (133, $curY );
//$pdf->SetXY(133, $curY );
//$pdf->MultiCell(10, 5, $object->lines[$i]->tva_tx, 0, 'C');
$pdf->SetXY (145, $curY );
$pdf->SetXY(145, $curY );
$pdf->MultiCell(10, 3, $object->lines[$i]->qty_shipped, 0, 'C');
// TODO Field not yet saved in database
//$pdf->SetXY (156, $curY );
//$pdf->SetXY(156, $curY );
//$pdf->MultiCell(20, 3, price($object->lines[$i]->price), 0, 'R', 0);
// TODO Field not yet saved in database
//$pdf->SetXY (174, $curY );
//$pdf->SetXY(174, $curY );
//$total = price($object->lines[$i]->price * $object->lines[$i]->qty_shipped);
//$pdf->MultiCell(26, 3, $total, 0, 'R', 0);

View File

@@ -205,7 +205,7 @@ class pdf_typhon extends ModelePDFDeliveryOrder
$tab_top = 88;
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-$tab_top;
@@ -243,26 +243,26 @@ class pdf_typhon extends ModelePDFDeliveryOrder
/*
// TVA
$pdf->SetXY ($this->posxtva, $curY);
$pdf->SetXY($this->posxtva, $curY);
$pdf->MultiCell(10, 4, ($object->lines[$i]->tva_tx < 0 ? '*':'').abs($object->lines[$i]->tva_tx), 0, 'R');
// Prix unitaire HT avant remise
$pdf->SetXY ($this->posxup, $curY);
$pdf->SetXY($this->posxup, $curY);
$pdf->MultiCell(20, 4, price($object->lines[$i]->subprice), 0, 'R', 0);
*/
// Quantity
$pdf->SetXY ($this->posxqty, $curY);
$pdf->SetXY($this->posxqty, $curY);
$pdf->MultiCell(30, 3, $object->lines[$i]->qty_shipped, 0, 'R');
/*
// Remise sur ligne
$pdf->SetXY ($this->posxdiscount, $curY);
$pdf->SetXY($this->posxdiscount, $curY);
if ($object->lines[$i]->remise_percent)
{
$pdf->MultiCell(14, 3, $object->lines[$i]->remise_percent."%", 0, 'R');
}
// Total HT ligne
$pdf->SetXY ($this->postotalht, $curY);
$pdf->SetXY($this->postotalht, $curY);
$total = price($object->lines[$i]->price * $object->lines[$i]->qty);
$pdf->MultiCell(23, 3, $total, 0, 'R', 0);
@@ -438,28 +438,28 @@ class pdf_typhon extends ModelePDFDeliveryOrder
$pdf->SetTextColor(0,0,0);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+1);
$pdf->SetXY($this->posxdesc-1, $tab_top+1);
$pdf->MultiCell(80,2, $outputlangs->transnoentities("Designation"),'','L');
// Modif SEB pour avoir une col en plus pour les commentaires clients
$pdf->line($this->posxcomm, $tab_top, $this->posxcomm, $tab_top + $tab_height);
$pdf->SetXY ($this->posxcomm, $tab_top+1);
$pdf->SetXY($this->posxcomm, $tab_top+1);
$pdf->MultiCell(80,2, $outputlangs->transnoentities("Comments"),'','L');
// Qty
$pdf->line($this->posxqty-1, $tab_top, $this->posxqty-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqty-1, $tab_top+1);
$pdf->SetXY($this->posxqty-1, $tab_top+1);
$pdf->MultiCell(30, 2, $outputlangs->transnoentities("QtyShipped"),'','R');
// Modif Seb cadres signatures
$pdf->SetFont('','', $default_font_size);
$larg_sign = ($this->page_largeur-$this->marge_gauche-$this->marge_droite)/3;
$pdf->Rect($this->marge_gauche, ($tab_top + $tab_height + 3), $larg_sign, 25 );
$pdf->SetXY ($this->marge_gauche + 2, $tab_top + $tab_height + 5);
$pdf->SetXY($this->marge_gauche + 2, $tab_top + $tab_height + 5);
$pdf->MultiCell($larg_sign,2, $outputlangs->trans("For").' '.$outputlangs->convToOutputCharset($mysoc->name).":",'','L');
$pdf->Rect(2*$larg_sign+$this->marge_gauche, ($tab_top + $tab_height + 3), $larg_sign, 25 );
$pdf->SetXY (2*$larg_sign+$this->marge_gauche + 2, $tab_top + $tab_height + 5);
$pdf->SetXY(2*$larg_sign+$this->marge_gauche + 2, $tab_top + $tab_height + 5);
$pdf->MultiCell($larg_sign,2, $outputlangs->trans("ForCustomer").':','','L');
}

View File

@@ -344,14 +344,14 @@ class pdf_standard {
$this->_Metric = $format['metric'];
$this->_Avery_Name = $format['name'];
$this->_Avery_Code = $format['code'];
$this->_Margin_Left = $this->_Convert_Metric ($format['marginLeft'], $this->_Metric, $this->_Metric_Doc);
$this->_Margin_Top = $this->_Convert_Metric ($format['marginTop'], $this->_Metric, $this->_Metric_Doc);
$this->_X_Space = $this->_Convert_Metric ($format['SpaceX'], $this->_Metric, $this->_Metric_Doc);
$this->_Y_Space = $this->_Convert_Metric ($format['SpaceY'], $this->_Metric, $this->_Metric_Doc);
$this->_Margin_Left = $this->_Convert_Metric($format['marginLeft'], $this->_Metric, $this->_Metric_Doc);
$this->_Margin_Top = $this->_Convert_Metric($format['marginTop'], $this->_Metric, $this->_Metric_Doc);
$this->_X_Space = $this->_Convert_Metric($format['SpaceX'], $this->_Metric, $this->_Metric_Doc);
$this->_Y_Space = $this->_Convert_Metric($format['SpaceY'], $this->_Metric, $this->_Metric_Doc);
$this->_X_Number = $format['NX'];
$this->_Y_Number = $format['NY'];
$this->_Width = $this->_Convert_Metric ($format['width'], $this->_Metric, $this->_Metric_Doc);
$this->_Height = $this->_Convert_Metric ($format['height'], $this->_Metric, $this->_Metric_Doc);
$this->_Width = $this->_Convert_Metric($format['width'], $this->_Metric, $this->_Metric_Doc);
$this->_Height = $this->_Convert_Metric($format['height'], $this->_Metric, $this->_Metric_Doc);
$this->Set_Char_Size($pdf, $format['font-size']);
}

View File

@@ -323,14 +323,14 @@ class pdf_standardlabel {
$this->_Metric = $format['metric'];
$this->_Avery_Name = $format['name'];
$this->_Avery_Code = $format['code'];
$this->_Margin_Left = $this->_Convert_Metric ($format['marginLeft'], $this->_Metric, $this->_Metric_Doc);
$this->_Margin_Top = $this->_Convert_Metric ($format['marginTop'], $this->_Metric, $this->_Metric_Doc);
$this->_X_Space = $this->_Convert_Metric ($format['SpaceX'], $this->_Metric, $this->_Metric_Doc);
$this->_Y_Space = $this->_Convert_Metric ($format['SpaceY'], $this->_Metric, $this->_Metric_Doc);
$this->_Margin_Left = $this->_Convert_Metric($format['marginLeft'], $this->_Metric, $this->_Metric_Doc);
$this->_Margin_Top = $this->_Convert_Metric($format['marginTop'], $this->_Metric, $this->_Metric_Doc);
$this->_X_Space = $this->_Convert_Metric($format['SpaceX'], $this->_Metric, $this->_Metric_Doc);
$this->_Y_Space = $this->_Convert_Metric($format['SpaceY'], $this->_Metric, $this->_Metric_Doc);
$this->_X_Number = $format['NX'];
$this->_Y_Number = $format['NY'];
$this->_Width = $this->_Convert_Metric ($format['width'], $this->_Metric, $this->_Metric_Doc);
$this->_Height = $this->_Convert_Metric ($format['height'], $this->_Metric, $this->_Metric_Doc);
$this->_Width = $this->_Convert_Metric($format['width'], $this->_Metric, $this->_Metric_Doc);
$this->_Height = $this->_Convert_Metric($format['height'], $this->_Metric, $this->_Metric_Doc);
$this->Set_Char_Size($pdf, $format['font-size']);
}

View File

@@ -172,7 +172,7 @@ class pdf_baleine extends ModelePDFProjects
if (! empty($object->note_public))
{
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->posxref-1, $tab_top-2);
$pdf->SetXY($this->posxref-1, $tab_top-2);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-($tab_top-2);
@@ -309,7 +309,7 @@ class pdf_baleine extends ModelePDFProjects
$pdf->SetTextColor(0,0,0);
$pdf->SetFont('','', $default_font_size);
$pdf->SetXY ($this->posxref-1, $tab_top+2);
$pdf->SetXY($this->posxref-1, $tab_top+2);
$pdf->MultiCell(80,2, $outputlangs->transnoentities("Tasks"),'','L');
}

View File

@@ -214,7 +214,7 @@ class pdf_propale_azur extends ModelePDFPropales
$tab_top = 88;
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 4, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-$tab_top;
@@ -253,22 +253,22 @@ class pdf_propale_azur extends ModelePDFPropales
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxtva, $curY);
$pdf->SetXY($this->posxtva, $curY);
$pdf->MultiCell($this->posxup-$this->posxtva-1, 4, $vat_rate, 0, 'R');
}
// Prix unitaire HT avant remise
$up_excl_tax = pdf_getlineupexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxup, $curY);
$pdf->SetXY($this->posxup, $curY);
$pdf->MultiCell($this->posxqty-$this->posxup-1, 4, $up_excl_tax, 0, 'R', 0);
// Quantity
$qty = pdf_getlineqty($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxqty, $curY);
$pdf->SetXY($this->posxqty, $curY);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1, 4, $qty, 0, 'R');
// Remise sur ligne
$pdf->SetXY ($this->posxdiscount, $curY);
$pdf->SetXY($this->posxdiscount, $curY);
if ($object->lines[$i]->remise_percent)
{
$remise_percent = pdf_getlineremisepercent($object, $i, $outputlangs, $hidedetails, $hookmanager);
@@ -277,7 +277,7 @@ class pdf_propale_azur extends ModelePDFPropales
// Total HT ligne
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->postotalht, $curY);
$pdf->SetXY($this->postotalht, $curY);
$pdf->MultiCell(26, 4, $total_excl_tax, 0, 'R', 0);
// Collecte des totaux par valeur de tva dans $this->tva["taux"]=total_tva
@@ -599,10 +599,10 @@ class pdf_propale_azur extends ModelePDFPropales
// Total HT
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + 0);
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + 0);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + $object->remise), 0, 'R', 1);
$index = 0;
@@ -620,7 +620,7 @@ class pdf_propale_azur extends ModelePDFPropales
$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -632,7 +632,7 @@ class pdf_propale_azur extends ModelePDFPropales
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -640,19 +640,19 @@ class pdf_propale_azur extends ModelePDFPropales
if (! $this->atleastoneratenotnull) // If not vat at all
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalVAT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_tva), 0, 'R', 1);
// Total LocalTax1
if (! empty($conf->global->FACTURE_LOCAL_TAX1_OPTION) && $conf->global->FACTURE_LOCAL_TAX1_OPTION=='localtax1on' && $object->total_localtax1>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT1".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax1), $useborder, 'R', 1);
}
@@ -660,9 +660,9 @@ class pdf_propale_azur extends ModelePDFPropales
if (! empty($conf->global->FACTURE_LOCAL_TAX2_OPTION) && $conf->global->FACTURE_LOCAL_TAX2_OPTION=='localtax2on' && $object->total_localtax2>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT2".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax2), $useborder, 'R', 1);
}
}
@@ -678,7 +678,7 @@ class pdf_propale_azur extends ModelePDFPropales
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -690,7 +690,7 @@ class pdf_propale_azur extends ModelePDFPropales
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -706,7 +706,7 @@ class pdf_propale_azur extends ModelePDFPropales
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -718,7 +718,7 @@ class pdf_propale_azur extends ModelePDFPropales
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
@@ -733,12 +733,12 @@ class pdf_propale_azur extends ModelePDFPropales
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
$pdf->SetTextColor(0,0,0);
}
@@ -747,10 +747,10 @@ class pdf_propale_azur extends ModelePDFPropales
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle), 0, 'R', 0);
$resteapayer = $object->total_ttc - $deja_regle;
@@ -761,10 +761,10 @@ class pdf_propale_azur extends ModelePDFPropales
$index++;
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("EscompteOffered"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle), $useborder, 'R', 1);
$resteapayer=0;
@@ -773,10 +773,10 @@ class pdf_propale_azur extends ModelePDFPropales
$index++;
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), $useborder, 'R', 1);
// Fin
@@ -814,28 +814,28 @@ class pdf_propale_azur extends ModelePDFPropales
$pdf->SetFont('','',$default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+1);
$pdf->SetXY($this->posxdesc-1, $tab_top+1);
$pdf->MultiCell(108,2, $outputlangs->transnoentities("Designation"),'','L');
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$pdf->line($this->posxtva-1, $tab_top, $this->posxtva-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxtva-3, $tab_top+1);
$pdf->SetXY($this->posxtva-3, $tab_top+1);
$pdf->MultiCell($this->posxup-$this->posxtva+3,2, $outputlangs->transnoentities("VAT"),'','C');
}
$pdf->line($this->posxup-1, $tab_top, $this->posxup-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxup-1, $tab_top+1);
$pdf->SetXY($this->posxup-1, $tab_top+1);
$pdf->MultiCell($this->posxqty-$this->posxup-1,2, $outputlangs->transnoentities("PriceUHT"),'','C');
$pdf->line($this->posxqty-1, $tab_top, $this->posxqty-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqty-1, $tab_top+1);
$pdf->SetXY($this->posxqty-1, $tab_top+1);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1,2, $outputlangs->transnoentities("Qty"),'','C');
$pdf->line($this->posxdiscount-1, $tab_top, $this->posxdiscount-1, $tab_top + $tab_height);
if ($this->atleastonediscount)
{
$pdf->SetXY ($this->posxdiscount-1, $tab_top+1);
$pdf->SetXY($this->posxdiscount-1, $tab_top+1);
$pdf->MultiCell($this->postotalht-$this->posxdiscount+1,2, $outputlangs->transnoentities("ReductionShort"),'','C');
}
@@ -843,7 +843,7 @@ class pdf_propale_azur extends ModelePDFPropales
{
$pdf->line($this->postotalht, $tab_top, $this->postotalht, $tab_top + $tab_height);
}
$pdf->SetXY ($this->postotalht-1, $tab_top+1);
$pdf->SetXY($this->postotalht-1, $tab_top+1);
$pdf->MultiCell(30,2, $outputlangs->transnoentities("TotalHT"),'','C');
}

View File

@@ -214,7 +214,7 @@ class pdf_propale_jaune extends ModelePDFPropales
$tab_top = 88;
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 4, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-$tab_top;
@@ -253,22 +253,22 @@ class pdf_propale_jaune extends ModelePDFPropales
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxtva, $curY);
$pdf->SetXY($this->posxtva, $curY);
$pdf->MultiCell($this->posxup-$this->posxtva-1, 4, $vat_rate, 0, 'R');
}
// Prix unitaire HT avant remise
$up_excl_tax = pdf_getlineupexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxup, $curY);
$pdf->SetXY($this->posxup, $curY);
$pdf->MultiCell($this->posxqty-$this->posxup-1, 4, $up_excl_tax, 0, 'R', 0);
// Quantity
$qty = pdf_getlineqty($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->posxqty, $curY);
$pdf->SetXY($this->posxqty, $curY);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1, 4, $qty, 0, 'R');
// Remise sur ligne
$pdf->SetXY ($this->posxdiscount, $curY);
$pdf->SetXY($this->posxdiscount, $curY);
if ($object->lines[$i]->remise_percent)
{
$remise_percent = pdf_getlineremisepercent($object, $i, $outputlangs, $hidedetails, $hookmanager);
@@ -277,7 +277,7 @@ class pdf_propale_jaune extends ModelePDFPropales
// Total HT ligne
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs, $hidedetails, $hookmanager);
$pdf->SetXY ($this->postotalht, $curY);
$pdf->SetXY($this->postotalht, $curY);
$pdf->MultiCell(26, 4, $total_excl_tax, 0, 'R', 0);
// Collecte des totaux par valeur de tva dans $this->tva["taux"]=total_tva
@@ -599,10 +599,10 @@ class pdf_propale_jaune extends ModelePDFPropales
// Total HT
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + 0);
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + 0);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + $object->remise), 0, 'R', 1);
$index = 0;
@@ -620,7 +620,7 @@ class pdf_propale_jaune extends ModelePDFPropales
$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -632,7 +632,7 @@ class pdf_propale_jaune extends ModelePDFPropales
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -640,19 +640,19 @@ class pdf_propale_jaune extends ModelePDFPropales
if (! $this->atleastoneratenotnull) // If not vat at all
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalVAT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_tva), 0, 'R', 1);
// Total LocalTax1
if (! empty($conf->global->FACTURE_LOCAL_TAX1_OPTION) && $conf->global->FACTURE_LOCAL_TAX1_OPTION=='localtax1on' && $object->total_localtax1>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT1".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax1), $useborder, 'R', 1);
}
@@ -660,9 +660,9 @@ class pdf_propale_jaune extends ModelePDFPropales
if (! empty($conf->global->FACTURE_LOCAL_TAX2_OPTION) && $conf->global->FACTURE_LOCAL_TAX2_OPTION=='localtax2on' && $object->total_localtax2>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT2".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax2), $useborder, 'R', 1);
}
}
@@ -678,7 +678,7 @@ class pdf_propale_jaune extends ModelePDFPropales
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -690,7 +690,7 @@ class pdf_propale_jaune extends ModelePDFPropales
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -706,7 +706,7 @@ class pdf_propale_jaune extends ModelePDFPropales
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -718,7 +718,7 @@ class pdf_propale_jaune extends ModelePDFPropales
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
@@ -733,12 +733,12 @@ class pdf_propale_jaune extends ModelePDFPropales
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,124);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
$pdf->SetTextColor(0,0,0);
}
@@ -747,10 +747,10 @@ class pdf_propale_jaune extends ModelePDFPropales
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle), 0, 'R', 0);
$resteapayer = $object->total_ttc - $deja_regle;
@@ -761,10 +761,10 @@ class pdf_propale_jaune extends ModelePDFPropales
$index++;
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("EscompteOffered"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle), $useborder, 'R', 1);
$resteapayer=0;
@@ -773,10 +773,10 @@ class pdf_propale_jaune extends ModelePDFPropales
$index++;
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($resteapayer), $useborder, 'R', 1);
// Fin
@@ -814,28 +814,28 @@ class pdf_propale_jaune extends ModelePDFPropales
$pdf->SetFont('','',$default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+1);
$pdf->SetXY($this->posxdesc-1, $tab_top+1);
$pdf->MultiCell(108,2, $outputlangs->transnoentities("Designation"),'','L');
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$pdf->line($this->posxtva-1, $tab_top, $this->posxtva-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxtva-3, $tab_top+1);
$pdf->SetXY($this->posxtva-3, $tab_top+1);
$pdf->MultiCell($this->posxup-$this->posxtva+3,2, $outputlangs->transnoentities("VAT"),'','C');
}
$pdf->line($this->posxup-1, $tab_top, $this->posxup-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxup-1, $tab_top+1);
$pdf->SetXY($this->posxup-1, $tab_top+1);
$pdf->MultiCell($this->posxqty-$this->posxup-1,2, $outputlangs->transnoentities("PriceUHT"),'','C');
$pdf->line($this->posxqty-1, $tab_top, $this->posxqty-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqty-1, $tab_top+1);
$pdf->SetXY($this->posxqty-1, $tab_top+1);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1,2, $outputlangs->transnoentities("Qty"),'','C');
$pdf->line($this->posxdiscount-1, $tab_top, $this->posxdiscount-1, $tab_top + $tab_height);
if ($this->atleastonediscount)
{
$pdf->SetXY ($this->posxdiscount-1, $tab_top+1);
$pdf->SetXY($this->posxdiscount-1, $tab_top+1);
$pdf->MultiCell($this->postotalht-$this->posxdiscount+1,2, $outputlangs->transnoentities("ReductionShort"),'','C');
}
@@ -843,7 +843,7 @@ class pdf_propale_jaune extends ModelePDFPropales
{
$pdf->line($this->postotalht, $tab_top, $this->postotalht, $tab_top + $tab_height);
}
$pdf->SetXY ($this->postotalht-1, $tab_top+1);
$pdf->SetXY($this->postotalht-1, $tab_top+1);
$pdf->MultiCell(30,2, $outputlangs->transnoentities("TotalHT"),'','C');
}

View File

@@ -227,31 +227,31 @@ class pdf_paiement
$pdf->SetFont('','',10);
$pdf->SetXY (11, 16);
$pdf->SetXY(11, 16);
$pdf->MultiCell(80, 2, $outputlangs->transnoentities("DateBuild")." : ".dol_print_date(time(),"day",false,$outputlangs,true), 0, 'L');
$pdf->SetXY (11, 22);
$pdf->SetXY(11, 22);
$pdf->MultiCell(80, 2, $outputlangs->transnoentities("Page")." : ".$page, 0, 'L');
// Title line
$pdf->SetXY (11, $this->tab_top+2);
$pdf->SetXY(11, $this->tab_top+2);
$pdf->MultiCell(30, 2, 'Date');
$pdf->line(40, $this->tab_top, 40, $this->tab_top + $this->tab_height + 10);
$pdf->SetXY (42, $this->tab_top+2);
$pdf->SetXY(42, $this->tab_top+2);
$pdf->MultiCell(40, 2, $outputlangs->transnoentities("PaymentMode"), 0, 'L');
$pdf->line(80, $this->tab_top, 80, $this->tab_top + $this->tab_height + 10);
$pdf->SetXY (82, $this->tab_top+2);
$pdf->SetXY(82, $this->tab_top+2);
$pdf->MultiCell(40, 2, $outputlangs->transnoentities("Invoice"), 0, 'L');
$pdf->line(120, $this->tab_top, 120, $this->tab_top + $this->tab_height + 10);
$pdf->SetXY (122, $this->tab_top+2);
$pdf->SetXY(122, $this->tab_top+2);
$pdf->MultiCell(40, 2, $outputlangs->transnoentities("AmountInvoice"), 0, 'L');
$pdf->line(160, $this->tab_top, 160, $this->tab_top + $this->tab_height + 10);
$pdf->SetXY (162, $this->tab_top+2);
$pdf->SetXY(162, $this->tab_top+2);
$pdf->MultiCell(40, 2, $outputlangs->transnoentities("AmountPayment"), 0, 'L');
$pdf->line(10, $this->tab_top + 10, 200, $this->tab_top + 10 );
@@ -284,28 +284,28 @@ class pdf_paiement
$yp = 0;
}
$pdf->SetXY (10, $this->tab_top + 10 + $yp);
$pdf->SetXY(10, $this->tab_top + 10 + $yp);
$pdf->MultiCell(30, $this->line_height, $lines[$j][1], 0, 'L', 1);
$pdf->SetXY (40, $this->tab_top + 10 + $yp);
$pdf->SetXY(40, $this->tab_top + 10 + $yp);
$pdf->MultiCell(80, $this->line_height, $lines[$j][2].' '.$lines[$j][3], 0, 'L', 1);
$pdf->SetXY (120, $this->tab_top + 10 + $yp);
$pdf->SetXY(120, $this->tab_top + 10 + $yp);
$pdf->MultiCell(40, $this->line_height, '', 0, 'R', 1);
$pdf->SetXY (160, $this->tab_top + 10 + $yp);
$pdf->SetXY(160, $this->tab_top + 10 + $yp);
$pdf->MultiCell(40, $this->line_height, $lines[$j][4], 0, 'R', 1);
$yp = $yp + 5;
}
// Invoice number
$pdf->SetXY (80, $this->tab_top + 10 + $yp);
$pdf->SetXY(80, $this->tab_top + 10 + $yp);
$pdf->MultiCell(40, $this->line_height, $lines[$j][0], 0, 'L', 0);
$pdf->SetXY (120, $this->tab_top + 10 + $yp);
$pdf->SetXY(120, $this->tab_top + 10 + $yp);
$pdf->MultiCell(40, $this->line_height, $lines[$j][5], 0, 'R', 0);
$pdf->SetXY (160, $this->tab_top + 10 + $yp);
$pdf->SetXY(160, $this->tab_top + 10 + $yp);
$pdf->MultiCell(40, $this->line_height, $lines[$j][6], 0, 'R', 0);
$yp = $yp + 5;

View File

@@ -220,7 +220,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$tab_top = 88;
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-$tab_top;
@@ -260,20 +260,20 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs);
$pdf->SetXY ($this->posxtva, $curY);
$pdf->SetXY($this->posxtva, $curY);
$pdf->MultiCell($this->posxup-$this->posxtva-1, 3, $vat_rate, 0, 'R');
}
// Unit price before discount
$pdf->SetXY ($this->posxup, $curY);
$pdf->SetXY($this->posxup, $curY);
$pdf->MultiCell($this->posxqty-$this->posxup-1, 3, price($object->lines[$i]->pu_ht), 0, 'R', 0);
// Quantity
$pdf->SetXY ($this->posxqty, $curY);
$pdf->SetXY($this->posxqty, $curY);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1, 3, $object->lines[$i]->qty, 0, 'R');
// Discount on line
$pdf->SetXY ($this->posxdiscount, $curY);
$pdf->SetXY($this->posxdiscount, $curY);
if ($object->lines[$i]->remise_percent)
{
$pdf->MultiCell($this->postotalht-$this->posxdiscount-1, 3, $object->lines[$i]->remise_percent."%", 0, 'R');
@@ -281,7 +281,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
// Total HT line
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs);
$pdf->SetXY ($this->postotalht, $curY);
$pdf->SetXY($this->postotalht, $curY);
$pdf->MultiCell(26, 3, $total_excl_tax, 0, 'R', 0);
// Collecte des totaux par valeur de tva dans $this->tva["taux"]=total_tva
@@ -403,7 +403,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$tab2_hl = 4;
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->marge_gauche, $tab2_top + 0);
$pdf->SetXY($this->marge_gauche, $tab2_top + 0);
// If France, show VAT mention if not applicable
if ($this->emetteur->pays_code == 'FR' && $this->franchise == 1)
{
@@ -415,9 +415,9 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
// Total HT
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + 0);
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + 0);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + $object->remise), 0, 'R', 1);
// Affichage des totaux de TVA par taux (conformement a reglementation)
@@ -430,7 +430,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
@@ -444,25 +444,25 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
if (! $this->atleastoneratenotnull) // If not vat at all
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalVAT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_tva), 0, 'R', 1);
// Total LocalTax1
if (! empty($conf->global->FACTURE_LOCAL_TAX1_OPTION) && $conf->global->FACTURE_LOCAL_TAX1_OPTION=='localtax1on' && $object->total_localtax1>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT1".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax1), $useborder, 'R', 1);
}
@@ -470,9 +470,9 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
if (! empty($conf->global->FACTURE_LOCAL_TAX2_OPTION) && $conf->global->FACTURE_LOCAL_TAX2_OPTION=='localtax2on' && $object->total_localtax2>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT2".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax2), $useborder, 'R', 1);
}
}
@@ -488,7 +488,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -500,7 +500,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -516,7 +516,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -528,7 +528,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -538,12 +538,12 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$useborder=0;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetTextColor(0,0,0);
@@ -552,19 +552,19 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle), 0, 'R', 0);
$index++;
$pdf->SetTextColor(0,0,60);
//$pdf->SetFont('','B', $default_font_size - 1);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle), $useborder, 'R', 1);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetTextColor(0,0,0);
@@ -600,29 +600,29 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+2);
$pdf->SetXY($this->posxdesc-1, $tab_top+2);
$pdf->MultiCell(108,2, $outputlangs->transnoentities("Designation"),'','L');
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$pdf->line($this->posxtva-1, $tab_top, $this->posxtva-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxtva-3, $tab_top+2);
$pdf->SetXY($this->posxtva-3, $tab_top+2);
$pdf->MultiCell($this->posxup-$this->posxtva+3,2, $outputlangs->transnoentities("VAT"),'','C');
}
$pdf->line($this->posxup-1, $tab_top, $this->posxup-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxup-1, $tab_top+2);
$pdf->SetXY($this->posxup-1, $tab_top+2);
$pdf->MultiCell($this->posxqty-$this->posxup-1,2, $outputlangs->transnoentities("PriceUHT"),'','C');
$pdf->line($this->posxqty-1, $tab_top, $this->posxqty-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqty-1, $tab_top+2);
$pdf->SetXY($this->posxqty-1, $tab_top+2);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1,2, $outputlangs->transnoentities("Qty"),'','C');
$pdf->line($this->posxdiscount-1, $tab_top, $this->posxdiscount-1, $tab_top + $tab_height);
if ($this->atleastonediscount)
{
$pdf->SetXY ($this->posxdiscount-1, $tab_top+2);
$pdf->SetXY($this->posxdiscount-1, $tab_top+2);
$pdf->MultiCell($this->postotalht-$this->posxdiscount+1,2, $outputlangs->transnoentities("ReductionShort"),'','C');
}
@@ -630,7 +630,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
{
$pdf->line($this->postotalht, $tab_top, $this->postotalht, $tab_top + $tab_height);
}
$pdf->SetXY ($this->postotalht-1, $tab_top+2);
$pdf->SetXY($this->postotalht-1, $tab_top+2);
$pdf->MultiCell(30,2, $outputlangs->transnoentities("TotalHTShort"),'','C');
}
@@ -653,19 +653,19 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$default_font_size = pdf_getPDFFontSize($outputlangs);
$pdf->SetFont('','', $default_font_size - 2);
$pdf->SetXY ($tab3_posx, $tab3_top - 5);
$pdf->SetXY($tab3_posx, $tab3_top - 5);
$pdf->MultiCell(60, 5, $outputlangs->transnoentities("PaymentsAlreadyDone"), 0, 'L', 0);
$pdf->line($tab3_posx, $tab3_top-1+$tab3_height, $tab3_posx+$tab3_width, $tab3_top-1+$tab3_height);
$pdf->SetFont('','', $default_font_size - 4);
$pdf->SetXY ($tab3_posx, $tab3_top );
$pdf->SetXY($tab3_posx, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Payment"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top );
$pdf->SetXY($tab3_posx+21, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Amount"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top );
$pdf->SetXY($tab3_posx+40, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Type"), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top );
$pdf->SetXY($tab3_posx+58, $tab3_top );
$pdf->MultiCell(20, 3, $outputlangs->transnoentities("Num"), 0, 'L', 0);
$y=0;
@@ -688,15 +688,15 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$y+=3;
$row = $this->db->fetch_object($resql);
$pdf->SetXY ($tab3_posx, $tab3_top+$y );
$pdf->SetXY($tab3_posx, $tab3_top+$y );
$pdf->MultiCell(20, 3, dol_print_date($this->db->jdate($row->date),'day',false,$outputlangs,true), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+21, $tab3_top+$y);
$pdf->SetXY($tab3_posx+21, $tab3_top+$y);
$pdf->MultiCell(20, 3, price($row->amount), 0, 'L', 0);
$pdf->SetXY ($tab3_posx+40, $tab3_top+$y);
$pdf->SetXY($tab3_posx+40, $tab3_top+$y);
$oper = $outputlangs->getTradFromKey("PaymentTypeShort" . $row->code);
$pdf->MultiCell(20, 3, $oper, 0, 'L', 0);
$pdf->SetXY ($tab3_posx+58, $tab3_top+$y);
$pdf->SetXY($tab3_posx+58, $tab3_top+$y);
$pdf->MultiCell(30, 3, $row->num, 0, 'L', 0);
$pdf->line($tab3_posx, $tab3_top+$y+3, $tab3_posx+$tab3_width, $tab3_top+$y+3 );

View File

@@ -223,7 +223,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$tab_top = 88;
$pdf->SetFont('','', $default_font_size - 1); // Dans boucle pour gerer multi-page
$pdf->SetXY ($this->posxdesc-1, $tab_top);
$pdf->SetXY($this->posxdesc-1, $tab_top);
$pdf->MultiCell(190, 3, $outputlangs->convToOutputCharset($object->note_public), 0, 'L');
$nexY = $pdf->GetY();
$height_note=$nexY-$tab_top;
@@ -261,20 +261,20 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs);
$pdf->SetXY ($this->posxtva, $curY);
$pdf->SetXY($this->posxtva, $curY);
$pdf->MultiCell($this->posxup-$this->posxtva-1, 3, $vat_rate, 0, 'R');
}
// Unit price before discount
$pdf->SetXY ($this->posxup, $curY);
$pdf->SetXY($this->posxup, $curY);
$pdf->MultiCell($this->posxqty-$this->posxup-1, 3, price($object->lines[$i]->subprice), 0, 'R', 0);
// Quantity
$pdf->SetXY ($this->posxqty, $curY);
$pdf->SetXY($this->posxqty, $curY);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1, 3, $object->lines[$i]->qty, 0, 'R');
// Discount on line
$pdf->SetXY ($this->posxdiscount, $curY);
$pdf->SetXY($this->posxdiscount, $curY);
if ($object->lines[$i]->remise_percent)
{
$pdf->MultiCell($this->postotalht-$this->posxdiscount-1, 3, $object->lines[$i]->remise_percent."%", 0, 'R');
@@ -282,7 +282,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
// Total HT line
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs);
$pdf->SetXY ($this->postotalht, $curY);
$pdf->SetXY($this->postotalht, $curY);
$pdf->MultiCell(26, 3, $total_excl_tax, 0, 'R', 0);
// Collecte des totaux par valeur de tva dans $this->tva["taux"]=total_tva
@@ -404,7 +404,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$tab2_hl = 4;
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->marge_gauche, $tab2_top + 0);
$pdf->SetXY($this->marge_gauche, $tab2_top + 0);
// If France, show VAT mention if not applicable
if ($this->emetteur->pays_code == 'FR' && $this->franchise == 1)
@@ -417,10 +417,10 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
// Total HT
$pdf->SetFillColor(255,255,255);
$pdf->SetXY ($col1x, $tab2_top + 0);
$pdf->SetXY($col1x, $tab2_top + 0);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalHT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + 0);
$pdf->SetXY($col2x, $tab2_top + 0);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ht + $object->remise), 0, 'R', 1);
// Affichage des totaux de TVA par taux (conformement a reglementation)
@@ -433,7 +433,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
@@ -447,26 +447,26 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
if (! $this->atleastoneratenotnull) // If not vat at all
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalVAT"), 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_tva), 0, 'R', 1);
// Total LocalTax1
if (! empty($conf->global->FACTURE_LOCAL_TAX1_OPTION) && $conf->global->FACTURE_LOCAL_TAX1_OPTION=='localtax1on' && $object->total_localtax1>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT1".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax1), $useborder, 'R', 1);
}
@@ -474,9 +474,9 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
if (! empty($conf->global->FACTURE_LOCAL_TAX2_OPTION) && $conf->global->FACTURE_LOCAL_TAX2_OPTION=='localtax2on' && $object->total_localtax2>0)
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalLT2".$mysoc->pays_code), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_localtax2), $useborder, 'R', 1);
}
}
@@ -492,7 +492,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -504,7 +504,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -520,7 +520,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
//$this->atleastoneratenotnull++;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$tvacompl='';
if (preg_match('/\*/',$tvakey))
@@ -532,7 +532,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$totalvat.=vatrate($tvakey,1).$tvacompl;
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $totalvat, 0, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($tvaval), 0, 'R', 1);
}
}
@@ -542,12 +542,12 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$useborder=0;
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetTextColor(0,0,60);
$pdf->SetFillColor(224,224,224);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("TotalTTC"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc), $useborder, 'R', 1);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetTextColor(0,0,0);
@@ -556,19 +556,19 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
{
$index++;
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("AlreadyPaid"), 0, 'L', 0);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($deja_regle), 0, 'R', 0);
$index++;
$pdf->SetTextColor(0,0,60);
//$pdf->SetFont('','B', $default_font_size - 1);
$pdf->SetXY ($col1x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col1x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($col2x-$col1x, $tab2_hl, $outputlangs->transnoentities("RemainderToPay"), $useborder, 'L', 1);
$pdf->SetXY ($col2x, $tab2_top + $tab2_hl * $index);
$pdf->SetXY($col2x, $tab2_top + $tab2_hl * $index);
$pdf->MultiCell($largcol2, $tab2_hl, price($object->total_ttc - $deja_regle), $useborder, 'R', 1);
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetTextColor(0,0,0);
@@ -604,28 +604,28 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$pdf->SetFont('','', $default_font_size - 1);
$pdf->SetXY ($this->posxdesc-1, $tab_top+2);
$pdf->SetXY($this->posxdesc-1, $tab_top+2);
$pdf->MultiCell(108,2, $outputlangs->transnoentities("Designation"),'','L');
if (empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT))
{
$pdf->line($this->posxtva-1, $tab_top, $this->posxtva-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxtva-3, $tab_top+2);
$pdf->SetXY($this->posxtva-3, $tab_top+2);
$pdf->MultiCell($this->posxup-$this->posxtva+3,2, $outputlangs->transnoentities("VAT"),'','C');
}
$pdf->line($this->posxup-1, $tab_top, $this->posxup-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxup-1, $tab_top+2);
$pdf->SetXY($this->posxup-1, $tab_top+2);
$pdf->MultiCell($this->posxqty-$this->posxup-1,2, $outputlangs->transnoentities("PriceUHT"),'','C');
$pdf->line($this->posxqty-1, $tab_top, $this->posxqty-1, $tab_top + $tab_height);
$pdf->SetXY ($this->posxqty-1, $tab_top+2);
$pdf->SetXY($this->posxqty-1, $tab_top+2);
$pdf->MultiCell($this->posxdiscount-$this->posxqty-1,2, $outputlangs->transnoentities("Qty"),'','C');
$pdf->line($this->posxdiscount-1, $tab_top, $this->posxdiscount-1, $tab_top + $tab_height);
if ($this->atleastonediscount)
{
$pdf->SetXY ($this->posxdiscount-1, $tab_top+2);
$pdf->SetXY($this->posxdiscount-1, $tab_top+2);
$pdf->MultiCell($this->postotalht-$this->posxdiscount+1,2, $outputlangs->transnoentities("ReductionShort"),'','C');
}
@@ -633,7 +633,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
{
$pdf->line($this->postotalht, $tab_top, $this->postotalht, $tab_top + $tab_height);
}
$pdf->SetXY ($this->postotalht-1, $tab_top+2);
$pdf->SetXY($this->postotalht-1, $tab_top+2);
$pdf->MultiCell(30,2, $outputlangs->transnoentities("TotalHTShort"),'','C');
}