Index: /views/mods/mod_rechnungen/accounting_pdf.phtml
===================================================================
--- /views/mods/mod_rechnungen/accounting_pdf.phtml	(revision 8301)
+++ /views/mods/mod_rechnungen/accounting_pdf.phtml	(revision 8302)
@@ -34,7 +34,4 @@
 	
 	$arCalculation = $this->view['basket']['arCalculation'];
-	
-	if ($this->getFrontendTaxView() === WPSG_NETTO) $taxdisplay = 'netto';
-	else $taxdisplay = 'brutto';
 
 	// Damit die Steuer bei der Kleinunternehmerregelung nicht angezeigt wird leer ich den Array sicherheitshalber
@@ -176,5 +173,4 @@
 	else if (!$bNoTax) $bTaxCol = true;
 
-
 	if ($bNoTax) {
 
@@ -183,4 +179,6 @@
 		$payment_cost = $this->view['basket']['arCalculation']['sum']['payment_netto'];
 
+		$taxdisplay = 'netto';
+
 	} else {
 
@@ -188,4 +186,6 @@
 		$shipping_cost = $this->view['basket']['arCalculation']['sum']['shipping_brutto'];
 		$payment_cost = $this->view['basket']['arCalculation']['sum']['payment_brutto'];
+
+		$taxdisplay = 'brutto';
 
 	}
@@ -484,9 +484,18 @@
 		{
 		
-			if ($this->arShipping[$this->view['data']['type_shipping']]['mwst_null'] == '1' && $bNoTax) $mwst = wpsg_ff(0.00, '%');
-			else {
-				
-				if ($this->view['basket']['arCalculation']['shipping'][0]['tax_key'] === '0') $mwst = _('anteilig');
-				else {
+			// if ($this->arShipping[$this->view['data']['type_shipping']]['mwst_null'] == '1' && $bNoTax) $mwst = wpsg_ff(0.00, '%');
+			// {
+			if ($bNoTax) 
+			{
+
+				$mwst = wpsg_ff(0.00, '%');
+
+			} else {
+				
+				if ($this->view['basket']['arCalculation']['shipping'][0]['tax_key'] === '0') {
+				
+					$mwst = _('anteilig');
+
+				} else {
 					
 					$mwst = wpsg_ff($this->view['basket']['arCalculation']['shipping'][0]['tax'], '%');
@@ -529,5 +538,7 @@
 		{
 		
-			if ($this->arPayment[$this->view['data']['type_payment']]['mwst_null'] == '1' && $bNoTax)
+			// if ($this->arPayment[$this->view['data']['type_payment']]['mwst_null'] == '1' && $bNoTax)
+			// {
+			if ($bNoTax) 
 			{
 
@@ -616,5 +627,18 @@
 	}
 	
-	$offset += 10; // Abstand zwischen Tabelle und Auswertung
+	$offset += 5; // Abstand zwischen Tabelle und Rabatt
+
+	// Rabatt
+	if ($discount_value > 0)
+	{
+		
+		$offset += 5;
+		$pdf->Text($prod_left + 80, $prod_top + $offset, __("Rabatt", "wpsg"));
+		$pdf->setXY($prod_left + 140, $prod_top + $offset - 5);
+		$pdf->Cell(37, 8, '-'.wpsg_ff($discount_value, $this->get_option('wpsg_currency')), 0, 0, 'R');
+		
+	}
+
+	$offset += 5; // Abstand zwischen Rabatt und Auswertung
 
 	if ( ($this->get_option('wpsg_kleinunternehmer') == '1') || ($this->view['oCalculationOrder']->getTaxMode() === \wpsg\wpsg_calculation::TAXMODE_SMALLBUSINESS) )
@@ -624,6 +648,7 @@
 		$pdf->Text($prod_left + 80, $prod_top + $offset, __("Summe", "wpsg"));
 		$pdf->setXY($prod_left + 140, $prod_top + $offset - 5);
-		$pdf->Cell(37, 8, wpsg_ff($this->view['basket']['arCalculation']['sum']['brutto'] + $this->view['basket']['arCalculation']['sum']['discount_brutto'], $this->get_option('wpsg_currency')), 0, 0, 'R');
-		if ( !$bNoTax || ($arCalculation['sum']['topay_brutto'] != $arCalculation['sum']['brutto']) ) $offset += 5;
+		$pdf->Cell(37, 8, wpsg_ff($this->view['basket']['arCalculation']['sum']['brutto'], $this->get_option('wpsg_currency')), 0, 0, 'R');
+
+		$offset += 5;
 
 	} else {
@@ -681,5 +706,5 @@
 			$pdf->Text($prod_left + 80, $prod_top + $offset, __("NETTOBETRAG", "wpsg"));
 			$pdf->setXY($prod_left + 140, $prod_top + $offset - 5);
-			$pdf->Cell(37, 8, wpsg_ff($this->view['basket']['arCalculation']['sum']['netto'] + $this->view['basket']['arCalculation']['sum']['discount_netto'], $this->get_option('wpsg_currency')), 0, 0, 'R');
+			$pdf->Cell(37, 8, wpsg_ff($this->view['basket']['arCalculation']['sum']['topay_netto'], $this->get_option('wpsg_currency')), 0, 0, 'R');
 			
 			if (sizeof($this->view['basket']['arCalculation']['tax']) >= 1)
@@ -716,15 +741,4 @@
 			
 		}
-		
-	}
-	
-	// Rabatt
-	if ($discount_value > 0)
-	{
-		
-		$offset += 5;
-		$pdf->Text($prod_left + 80, $prod_top + $offset, __("Rabatt", "wpsg"));
-		$pdf->setXY($prod_left + 140, $prod_top + $offset - 5);
-		$pdf->Cell(37, 8, '-'.wpsg_ff($discount_value, $this->get_option('wpsg_currency')), 0, 0, 'R');
 		
 	}
