X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FRP.pm;h=5bc2b4e3d112fd51ac02cfe1cfbb04c1f0af6b8b;hb=0463a0bb9deb1e683727ab2bf4900ebe49117f8a;hp=7bd324bce7efb6e00b6e17561b0da23e9bd00768;hpb=0576299f2aa98125991c4ffcd2f75073ea583d7d;p=kivitendo-erp.git diff --git a/SL/RP.pm b/SL/RP.pm index 7bd324bce..5bc2b4e3d 100644 --- a/SL/RP.pm +++ b/SL/RP.pm @@ -2343,6 +2343,10 @@ sub bwa { foreach $key (@periods) { $form->{ "$key" . "gesamtleistung" } = 0; $form->{ "$key" . "gesamtkosten" } = 0; + foreach $kosten (@gesamtkosten) { + $form->{$kosten}{$key} *= -1; + } + $form->{4}{$key} *= -1; foreach $category (@categories) { @@ -2357,6 +2361,7 @@ sub bwa { $form->{ "$key" . "gesamtleistung" } += $form->{$item}{$key}; } foreach $item (@gesamtkosten) { + $form->{$item}{$key} *= -1; $form->{ "$key" . "gesamtkosten" } += $form->{$item}{$key}; } $form->{ "$key" . "rohertrag" } = @@ -2552,12 +2557,12 @@ sub ustva { foreach $item (@categories_cent) { $form->{$item} = - $form->format_amount($myconfig, $form->round_amount($form->{$item}, 2)); + $form->format_amount($myconfig, $form->round_amount($form->{$item}, 2), 2, '0'); } foreach $item (@categories_euro) { $form->{$item} = - $form->format_amount($myconfig, $form->round_amount($form->{$item}, 0)); + $form->format_amount($myconfig, $form->round_amount($form->{$item}, 0), 0, '0'); } $dbh->disconnect;