USTVA: Taxbird und Winston werden nun beide unterstuetzt. Sie koennen ueber
[kivitendo-erp.git] / SL / User.pm
index d756a2a..62bc94f 100644 (file)
@@ -388,6 +388,9 @@ sub dbcreate {
   $filename = qq|sql/$form->{chart}-chart.sql|;
   $self->process_query($form, $dbh, $filename);
 
+  $query = "UPDATE defaults SET coa = " . $dbh->quote($form->{"chart"});
+  $dbh->do($query) || $form->dberror($query);
+
   $dbh->disconnect;
 
   $main::lxdebug->leave_sub();
@@ -409,6 +412,15 @@ sub process_perl_script {
 
   $dbh->begin_work();
 
+  my %dbup_myconfig = ();
+  map({ $dbup_myconfig{$_} = $form->{$_}; }
+      qw(dbname dbuser dbpasswd dbhost dbport dbconnect));
+
+  my $nls_file = $filename;
+  $nls_file =~ s|.*/||;
+  $nls_file =~ s|.pl$||;
+  my $dbup_locale = Locale->new($main::language, $nls_file);
+
   my $result = eval($contents);
 
   if (1 != $result) {