More work on invoice
This commit is contained in:
@@ -135,7 +135,7 @@ class Invoice_TCPDF_Default extends Invoice_TCPDF {
|
||||
|
||||
// Draw a box.
|
||||
$this->SetFillColor(245);
|
||||
$this->SetXY($x-1,$y-1); $this->Cell(0,35+($this->io->billed_amt ? 5 : 0)+($this->io->credit_amt ? 5 : 0),'',1,0,'',1);
|
||||
$this->SetXY($x-1,$y-1); $this->Cell(0,35+5+($this->io->credit_amt ? 5 : 0),'',1,0,'',1);
|
||||
|
||||
// Draw a box around the invoice due date and amount due.
|
||||
$this->SetFont('helvetica','B',11);
|
||||
@@ -166,13 +166,11 @@ class Invoice_TCPDF_Default extends Invoice_TCPDF {
|
||||
$this->SetFont('helvetica','B',11);
|
||||
$this->SetXY($x+55,$y); $this->Cell(0,0,$this->io->total(TRUE),0,0,'R');
|
||||
|
||||
if ($this->io->billed_amt) {
|
||||
$y += 5;
|
||||
$this->SetFont('helvetica','',10);
|
||||
$this->SetXY($x,$y); $this->Cell(0,0,'Payments Received');
|
||||
$this->SetFont('helvetica','B',11);
|
||||
$this->SetXY($x+55,$y); $this->Cell(0,0,$this->io->display('billed_amt'),0,0,'R');
|
||||
}
|
||||
$y += 5;
|
||||
$this->SetFont('helvetica','',10);
|
||||
$this->SetXY($x,$y); $this->Cell(0,0,'Payments Received');
|
||||
$this->SetFont('helvetica','B',11);
|
||||
$this->SetXY($x+55,$y); $this->Cell(0,0,$this->io->payments_total('TRUE'),0,0,'R');
|
||||
|
||||
if ($this->io->credit_amt) {
|
||||
$y += 5;
|
||||
@@ -321,7 +319,7 @@ class Invoice_TCPDF_Default extends Invoice_TCPDF {
|
||||
$this->SetFillColor(245);
|
||||
$this->SetXY($x-1,$y-1);
|
||||
$this->Cell(0,5*(
|
||||
1+1+1+3+($this->io->discount_amt ? 1 : 0)+($this->io->billed_amt ? 1 : 0)+($this->io->credit_amt ? 1 : 0)+$box
|
||||
1+1+1+3+($this->io->discount_amt ? 1 : 0)+1+($this->io->credit_amt ? 1 : 0)+$box
|
||||
)+1+4,'',1,0,'',1);
|
||||
|
||||
$this->SetFont('helvetica','B',11);
|
||||
@@ -409,15 +407,13 @@ class Invoice_TCPDF_Default extends Invoice_TCPDF {
|
||||
$this->Cell(0,0,Currency::display($this->io->total()),0,0,'R');
|
||||
|
||||
// Show payments already received for this invoice
|
||||
if ($this->io->billed_amt) {
|
||||
$y += 5;
|
||||
$this->SetY($y);
|
||||
$y += 5;
|
||||
$this->SetY($y);
|
||||
|
||||
$this->SetX($x+8);
|
||||
$this->Cell(0,0,'Payments Received');
|
||||
$this->SetX($x+135);
|
||||
$this->Cell(0,0,$this->io->payments_total(TRUE),0,0,'R');
|
||||
}
|
||||
$this->SetX($x+8);
|
||||
$this->Cell(0,0,'Payments Received');
|
||||
$this->SetX($x+135);
|
||||
$this->Cell(0,0,$this->io->payments_total(TRUE),0,0,'R');
|
||||
|
||||
if ($this->io->credit_amt) {
|
||||
$y += 5;
|
||||
|
Reference in New Issue
Block a user