Datenbank anlegen: ISO8859-1 als default eingestellt.
[kivitendo-erp.git] / bin / mozilla / arap.pl
index e7e2378..534a702 100644 (file)
@@ -49,13 +49,12 @@ sub check_name {
 
   my ($new_name, $new_id) = split /--/, $form->{$name};
   my $i = 0;
-
   # if we use a selection
   if ($form->{"select$name"}) {
     if ($form->{"old$name"} ne $form->{$name}) {
 
       # this is needed for is, ir and oe
-
+      $form->{update} = 0;
       # for credit calculations
       $form->{oldinvtotal}  = 0;
       $form->{oldtotalpaid} = 0;
@@ -76,6 +75,7 @@ sub check_name {
     if ($form->{"old$name"} ne qq|$form->{$name}--$form->{"${name}_id"}|) {
 
       # this is needed for is, ir and oe
+      $form->{update} = 0;
 
       # for credit calculations
       $form->{oldinvtotal}  = 0;
@@ -106,6 +106,7 @@ sub check_name {
       }
     }
   }
+  $form->language_payment(\%myconfig);
 
   $lxdebug->leave_sub();
 
@@ -236,7 +237,7 @@ sub name_selected {
 
   # delete all the new_ variables
   for $i (1 .. $form->{lastndx}) {
-    map { delete $form->{"new_${_}_$i"} } (id, name);
+    map { delete $form->{"new_${_}_$i"} } qw(id name);
   }
 
   map { delete $form->{$_} } qw(ndx lastndx nextsub);
@@ -441,8 +442,8 @@ sub project_selected {
 
 sub continue       { &{ $form->{nextsub} } }
 sub gl_transaction { &add }
-sub ar_transaction { &add_transaction(ar) }
-sub ap_transaction { &add_transaction(ap) }
-sub sales_invoice  { &add_transaction(is) }
-sub vendor_invoice { &add_transaction(ir) }
+sub ar_transaction { &add_transaction('ar') }
+sub ap_transaction { &add_transaction('ap') }
+sub sales_invoice  { &add_transaction('is') }
+sub vendor_invoice { &add_transaction('ir') }