From: Martin Helmling mh@waldpark.octosoft.eu Date: Mon, 27 Jul 2015 11:56:08 +0000 (+0200) Subject: Undefined chart bei taxkey 0 und 1 X-Git-Tag: release-3.3.0beta~25 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=5d140e0792ba53700a266f21fcb14a51852bde95;p=kivitendo-erp.git Undefined chart bei taxkey 0 und 1 Nicht nur bei Taxkey 0 gibt es keine chart_id, auch bei taxkey 1. Abfrage nun umgestellt. --- diff --git a/SL/Form.pm b/SL/Form.pm index 989a568cb..f94660648 100644 --- a/SL/Form.pm +++ b/SL/Form.pm @@ -3474,9 +3474,9 @@ sub calculate_arap { if ( $selected_tax ) { if ( $buysell eq 'sell' ) { - $self->{AR_amounts}{"tax_$i"} = $selected_tax->chart->accno unless $selected_tax->taxkey == 0; + $self->{AR_amounts}{"tax_$i"} = $selected_tax->chart->accno if defined $selected_tax->chart; } else { - $self->{AP_amounts}{"tax_$i"} = $selected_tax->chart->accno unless $selected_tax->taxkey == 0; + $self->{AP_amounts}{"tax_$i"} = $selected_tax->chart->accno if defined $selected_tax->chart; }; $self->{"taxkey_$i"} = $selected_tax->taxkey;