X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=bin%2Fmozilla%2Fam.pl;h=e12c1ea51b9b18e77913b2018c81d586943dfae0;hb=eb07c9dd23c32937527813cd0dea27a8ffe5603e;hp=c6bb8e47c1ea6a6ca0bf4cfe6b30c7c4594adc0d;hpb=de0f9532013c861dae78aa01b9633284d1ceee7c;p=kivitendo-erp.git
diff --git a/bin/mozilla/am.pl b/bin/mozilla/am.pl
index c6bb8e47c..e12c1ea51 100644
--- a/bin/mozilla/am.pl
+++ b/bin/mozilla/am.pl
@@ -42,12 +42,11 @@ use SL::User;
use SL::USTVA;
use SL::Iconv;
use SL::TODO;
-use SL::Printer;
-use CGI::Ajax;
+use SL::DB::Printer;
+use SL::DB::Tax;
+use SL::DB::Language;
use CGI;
-use Data::Dumper;
-
require "bin/mozilla/common.pl";
use strict;
@@ -147,7 +146,7 @@ sub account_header {
rate => '',
taxkey_id => '',
pos_ustva => '',
- startdate => '',
+ startdate => $form->{account_exists} ? '' : DateTime->new(year => 1970, month => 1, day => 1)->to_lxoffice,
};
push @{ $form->{ACCOUNT_TAXKEYS} }, $newtaxkey_ref;
@@ -331,31 +330,31 @@ sub account_header {
}
# preselection chart type
- my $select_charttype = q{};
-
- my %charttype = (
- 'A' => $locale->text('Account'),
- 'H' => $locale->text('Heading'),
- );
+ my @all_charttypes = ({'name' => $locale->text('Account'), 'value' => 'A'},
+ {'name' => $locale->text('Heading'), 'value' => 'H'},
+ );
+ my $selected_charttype = $form->{charttype};
- foreach my $item ( sort({ $a <=> $b } keys %charttype) ) {
- if ($item eq $form->{charttype}) {
- $select_charttype .= qq|