Line 176... |
Line 176... |
176 |
|
176 |
|
177 |
$pdf = new wpsg_fpdf();
|
177 |
$pdf = new wpsg_fpdf();
|
178 |
$pdf->SetAutoPageBreak(true, 5);
|
178 |
$pdf->SetAutoPageBreak(true, 5);
|
179 |
AddRechnungPage($this, $pdf);
|
179 |
AddRechnungPage($this, $pdf);
|
180 |
|
180 |
|
- |
|
181 |
if ($this->get_option('wpsg_deliverycountrytax') === '1') {
|
- |
|
182 |
$value = false;
|
- |
|
183 |
$kl = $this->view['kunde']['land'];
|
- |
|
184 |
if ( ($kl['mwst_a']) && ($kl['mwst_b']) && ($kl['mwst_c']) && ($kl['mwst_d']) == 0.0000 ) $value = true;
|
- |
|
185 |
$deliverycountrytax = $value;
|
- |
|
186 |
}
|
- |
|
187 |
|
- |
|
188 |
if (
|
181 |
if ( ($this->view['oCalculationOrder']->getTaxMode() === \wpsg\wpsg_calculation::TAXMODE_B2B && $this->view['oOrder']->isInnerEu())
|
189 |
( ($this->view['oCalculationOrder']->getTaxMode() === \wpsg\wpsg_calculation::TAXMODE_B2B) && ( $this->view['oOrder']->isInnerEu() || $deliverycountrytax ) )
|
- |
|
190 |
||
|
182 |
|| ($this->view['oCalculationOrder']->getTaxMode() === \wpsg\wpsg_calculation::TAXMODE_SMALLBUSINESS)
|
191 |
( $this->view['oCalculationOrder']->getTaxMode() === \wpsg\wpsg_calculation::TAXMODE_SMALLBUSINESS )
|
183 |
) $bNoTax = true;
|
192 |
) $bNoTax = true;
|
184 |
else $bNoTax = false;
|
193 |
else $bNoTax = false;
|
185 |
|
194 |
|
186 |
$bTaxCol = false;
|
195 |
$bTaxCol = false;
|
187 |
if ($this->get_option('wpsg_showMwstAlways') === '1') $bTaxCol = true;
|
196 |
if ($this->get_option('wpsg_showMwstAlways') === '1') $bTaxCol = true;
|
Line 648... |
Line 657... |
648 |
$pdf->setXY($prod_left + 140, $prod_top + $offset - 5);
|
657 |
$pdf->setXY($prod_left + 140, $prod_top + $offset - 5);
|
649 |
$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');
|
658 |
$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');
|
650 |
//if ( !$bNoTax || ($arCalculation['sum']['topay_brutto'] != $arCalculation['sum']['brutto']) )
|
659 |
//if ( !$bNoTax || ($arCalculation['sum']['topay_brutto'] != $arCalculation['sum']['brutto']) )
|
651 |
$offset += 5;
|
660 |
$offset += 5;
|
652 |
|
661 |
|
653 |
if ( !(($this->view['oOrder']->isInnerEu()) && ($this->view['oCalculationOrder']->getTaxMode() === \wpsg\wpsg_calculation::TAXMODE_B2B)) ) {
|
662 |
if ( !(($this->view['oOrder']->isInnerEu() || $deliverycountrytax) && ($this->view['oCalculationOrder']->getTaxMode() === \wpsg\wpsg_calculation::TAXMODE_B2B)) ) {
|
654 |
|
663 |
|
655 |
if (sizeof($this->view['basket']['arCalculation']['tax']) >= 1)
|
664 |
if (sizeof($this->view['basket']['arCalculation']['tax']) >= 1)
|
656 |
{
|
665 |
{
|
657 |
|
666 |
|
658 |
$mw_count = 0;
|
667 |
$mw_count = 0;
|