Ueber die Variable <%tax_rate%> kann nun in den Druckvorlagen der Steuersatz einer...
[kivitendo-erp.git] / SL / IS.pm
index a547fa9..c5950b1 100644 (file)
--- a/SL/IS.pm
+++ b/SL/IS.pm
@@ -214,7 +214,8 @@ sub invoice_details {
           $taxbase{$item} += $taxbase;
         }
       }
-
+      $tax_rate = $taxrate*100;
+      push(@{ $form->{tax_rate} }, qq|$tax_rate|);
       if ($form->{"assembly_$i"}) {
         $sameitem = "";
 
@@ -269,7 +270,7 @@ sub invoice_details {
 
       $tax += $taxamount = $form->round_amount($taxaccounts{$item}, 2);
 
-      push(@{ $form->{tax} }, $form->format_amount($myconfig, $taxamount));
+      push(@{ $form->{tax} }, $form->format_amount($myconfig, $taxamount, 2));
       push(@{ $form->{taxdescription} }, $form->{"${item}_description"});
       push(@{ $form->{taxrate} },
            $form->format_amount($myconfig, $form->{"${item}_rate"} * 100));
@@ -554,6 +555,7 @@ print STDERR "IS.pm-post_invoice\n";
 
       # get pricegroup_id and save ist
       ($null, my $pricegroup_id) = split /--/, $form->{"sellprice_drag_$i"};
+      $pricegroup_id *= 1;
 
       # save detail record in invoice table
       $query = qq|INSERT INTO invoice (trans_id, parts_id, description, qty,