X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fustva.pl;h=a3c464211291196fe8a730d0650d7b4379790b0e;hb=6de8e1614fb03b63967d06bd8522b4b46260832e;hp=9df5a663c668b9a5b5561414f106fd149c1c35b4;hpb=7f34b3c1f69619eaf3c41945ab22cf21883bb945;p=kivitendo-erp.git diff --git a/bin/mozilla/ustva.pl b/bin/mozilla/ustva.pl index 9df5a663c..a3c464211 100644 --- a/bin/mozilla/ustva.pl +++ b/bin/mozilla/ustva.pl @@ -23,6 +23,7 @@ # German Tax authority Module and later ELSTER Interface #====================================================================== +use strict; use utf8; require "bin/mozilla/common.pl"; @@ -847,7 +848,6 @@ sub generate_ustva { #file suffix $file .= '.xml'; $file =~ s|.*/||; - $form->{tmpfile} = "$::lx_office_conf{paths}{userspath}/$file"; $form->{attachment_filename} = $file; @@ -893,11 +893,9 @@ sub generate_ustva { # Define serveral filenames $form->{IN} = 'taxbird.txb'; - $form->{attachment_filename} = "USTVA-" . $form->{period} - . sprintf("%02d", $form->{year} % 100) . ".txb"; + $form->{attachment_filename} = "USTVA-" . ($form->{period} * 1) . sprintf("%02d", $form->{year} % 100) . ".txb"; $form->{attachment_filename} =~ s|.*/||; - $form->{tmpfile} = "$::lx_office_conf{paths}{userspath}/" . $form->{attachment_filename}; # TODO: set Output to UTF-8 or system Preference #$form->{"iconv"} = Text::Iconv->new($myconfig{dbcharset}, "UTF-8"); @@ -1106,13 +1104,13 @@ $::form->{title} = $::locale->text('Tax Office Preferences'); $::form->{title} = $::locale->text('Tax Office Preferences'); - my $select_tax_office = $ustva->fa_auswahl($land, $amt, $ustva->query_finanzamt(\%::myconfig, $::form)); - my $checked_accrual = q|checked="checked"| if ($::form->{method} eq 'accrual'); - my $checked_cash = q|checked="checked"| if ($::form->{method} eq 'cash'); - my $checked_monthly = "checked" if ($::form->{FA_voranmeld} eq 'month'); - my $checked_quarterly = "checked" if ($::form->{FA_voranmeld} eq 'quarter'); - my $checked_dauerfristverlaengerung = "checked" if ($::form->{FA_dauerfrist} eq '1'); - my $checked_kz_71 = "checked" if ($::form->{FA_71} eq 'X'); + my $select_tax_office = $ustva->fa_auswahl($land, $amt, $ustva->query_finanzamt(\%::myconfig, $::form)); + my $checked_accrual = $::form->{method} eq 'accrual' ? q|checked="checked"| : ''; + my $checked_cash = $::form->{method} eq 'cash' ? q|checked="checked"| : ''; + my $checked_monthly = $::form->{FA_voranmeld} eq 'month' ? "checked" : ''; + my $checked_quarterly = $::form->{FA_voranmeld} eq 'quarter' ? "checked" : ''; + my $checked_dauerfristverlaengerung = $::form->{FA_dauerfrist} eq '1' ? "checked" : ''; + my $checked_kz_71 = $::form->{FA_71} eq 'X' ? "checked" : ''; my $_hidden_variables_ref; @@ -1254,7 +1252,7 @@ sub config_step2 { my $patterncount = $form->{patterncount}; my $elster_pattern = $form->{elster_pattern}; my $delimiter = $form->{delimiter}; - my $steuernummer = $form->{steuernummer} if ($stnr eq ''); + my $steuernummer = $stnr eq '' ? $form->{steuernummer} : ''; $form->{FA_Oeffnungszeiten} =~ s/\\\\n/\n/g;