bugfix angebot Alternativ Text Preis

This commit is contained in:
OpenXE 2024-02-04 22:05:12 +01:00
parent 2efc34c280
commit 0360d5657f
2 changed files with 10 additions and 8 deletions

View File

@ -498,8 +498,10 @@ class AngebotPDF extends BriefpapierCustom {
"rabatt"=>$value['rabatt'],
"steuertext"=>$value['steuertext']));
if($positionenkaufmaenischrunden == 3){
$netto_gesamt = $value['menge'] * round($value['preis'] - ($value['preis'] / 100 * $value['rabatt']),2);
}else{
if (!$value['nicht_einrechnen']) {
$netto_gesamt = $value['menge'] * round($value['preis'] - ($value['preis'] / 100 * $value['rabatt']),2);
}
}else if (!$value['nicht_einrechnen']) {
$netto_gesamt = $value['menge'] * ($value['preis'] - ($value['preis'] / 100 * $value['rabatt']));
}
if($positionenkaufmaenischrunden)

View File

@ -658,7 +658,7 @@ class Briefpapier extends SuperFPDF {
public function addItem($rdata){
// add rabatt
if($rdata['price']!='-'){
if($rdata['price']!='-' && is_numeric($rdata['price'])){
if($rdata['rabatt'] == 100){
$rdata['tprice'] = round($rdata['amount'] * ((double)$rdata['price'] - (double)($rdata['price'] / 100.00 * (double)$rdata['rabatt'])), 13);
}else{
@ -4008,7 +4008,7 @@ class Briefpapier extends SuperFPDF {
}
$beschriftung_zeile = ucfirst($zwischenpositionen[$i]['postype']);
if($data['name']=="")
$html = ($fett?"<b>":"").$beschriftung_zeile.($fett?"</b>":"");
else
@ -4029,10 +4029,10 @@ class Briefpapier extends SuperFPDF {
$abstand_links = $posWidth +$itemNoWidth;
}
$this->SetX($x+$abstand_links);
$text = $this->WriteHTML($html);
$text = empty($text)?"":$text;
$this->SetX($x+$abstand_links);
$text = $this->WriteHTML($html);
$text = empty($text)?"":$text;
$this->Cell_typed($descWidth,4,);
$this->SetX($x+$abstand_links+$descWidth);