From: Sven Schöling Date: Thu, 30 Dec 2010 17:08:51 +0000 (+0100) Subject: Einkaufsrechnungen: Nicht auf den bereits formatierten Wechselkurs prüfen. X-Git-Tag: release-2.6.2beta1~13 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=ae45c5b76d87727e7113d7163e34a9f6444247e8;p=kivitendo-erp.git Einkaufsrechnungen: Nicht auf den bereits formatierten Wechselkurs prüfen. Fix für Bug 1517. --- diff --git a/bin/mozilla/ap.pl b/bin/mozilla/ap.pl index 06541ef05..35fef992e 100644 --- a/bin/mozilla/ap.pl +++ b/bin/mozilla/ap.pl @@ -244,17 +244,10 @@ sub form_header { $form->{forex} = $form->check_exchangerate( \%myconfig, $form->{currency}, $form->{transdate}, 'sell'); $form->{exchangerate} = $form->{forex} if $form->{forex}; - # format amounts - $form->{exchangerate} = - $form->format_amount(\%myconfig, $form->{exchangerate}); - if ($form->{exchangerate} == 0) { - $form->{exchangerate} = ""; - } - $form->{creditlimit} = - $form->format_amount(\%myconfig, $form->{creditlimit}, 0, "0"); - $form->{creditremaining} = - $form->format_amount(\%myconfig, $form->{creditremaining}, 0, "0"); + $form->{exchangerate} = $form->{exchangerate} ? $form->format_amount(\%myconfig, $form->{exchangerate}) : ''; + $form->{creditlimit} = $form->format_amount(\%myconfig, $form->{creditlimit}, 0, "0"); + $form->{creditremaining} = $form->format_amount(\%myconfig, $form->{creditremaining}, 0, "0"); my $exchangerate = qq| {forex}>