Hallo
Aktuell sitze ich an der Formatierung meiner PDF-Rechnung.
Soweit passt alles. Mit einer Ausnahme - ich bekomme den Rahmen von der Tabelle für die Artikel nicht weg. Der Rahmen vom Tabellenkopf hingegen ist weg.
Wo muss ich hier border auf 0 setzen?
Oder ganz woanders suchen?
Edit: Ganz vergessen - gibt es für die Zellen auch eine Art Padding-Angabe?
Danke euch. =)
Aktuell sitze ich an der Formatierung meiner PDF-Rechnung.
Soweit passt alles. Mit einer Ausnahme - ich bekomme den Rahmen von der Tabelle für die Artikel nicht weg. Der Rahmen vom Tabellenkopf hingegen ist weg.
Wo muss ich hier border auf 0 setzen?
PHP-Code:
function getTotalData() {
$data = array();
$i = 0;
foreach($this->order->totals as $key => $val) {
$data[$i]['title'] = strip_tags(html_entity_decode($val['title']));
$data[$i]['text'] = html_entity_decode($this->mr($val['text']));
$data[$i]['class'] = $val['class'];
$i++;
}
return $data;
}
function makeProducts($p = null) {
$productData = $this->getProductData($p);
$this->pdf->SetFont($this->fonts2['table'], '');
$this->pdf->SetFontSize($this->t1Opt['fontSize']);
$this->pdf->SetY($this->delta['invoiceProducts'] + $this->pdf->GetY());
$this->pdf->SetX($this->margin['left']);
// table-header
$this->pdf->SetFillColor(43,101,151);
$this->pdf->SetTextColor(255);
$this->pdf->SetFont($this->fonts2['bold']);
foreach($this->t1Col as $key => $value) {
if (is_null($this->t1Opt['cols'][$key]['width'])) {
$wi = 10;
} else {
$wi = $this->t1Opt['cols'][$key]['width'];
}
if($wi > 0){
$this->pdf->Cell($wi, $this->t1Opt['fontSize'] / 2, $value, '0', 0, $this->t1Opt['cols'][$key]['justification'], 1);
}
}
$this->pdf->SetTextColor(0);
$this->pdf->SetFont($this->fonts2['general']);
$this->pdf->SetXY($this->margin['left'], $this->pdf->GetY() + $this->t1Opt['fontSize'] / 2);
$i = 0;
$width = array();
$allign = array();
foreach($this->t1Col as $key => $value) {
$width[] = $value;
$allign[] = $this->t1Opt['cols'][$key]['justification'];
}
$this->SetAligns($allign);
foreach($productData as $pKey => $pValue) {
$mValue = array();
$width = array();
foreach($this->t1Col as $key => $value) {
if (is_null($this->t1Opt['cols'][$key]['width'])) {
$width[] = 10;
} else {
$width[] = $this->t1Opt['cols'][$key]['width'];
}
$mValue[] = $pValue[$key];
}
$this->SetWidths($width);
$this->subtotal += $mValue[$this->subtotalColumn];
$this->Row($mValue);
}
}
Edit: Ganz vergessen - gibt es für die Zellen auch eine Art Padding-Angabe?
Danke euch. =)