From 6d5d4f245d1a9a2f0b83b10c81272437a08126f7 Mon Sep 17 00:00:00 2001 From: Bernd Blessmann Date: Tue, 30 Mar 2010 15:30:04 +0200 Subject: [PATCH] Zahlungsbedingungen: skonto_in_percent kann verwendet werden. Im Langtext der Zahlungsbedingungen kann so der Prozentsatz des Skonto ausgegeben werden. --- SL/Form.pm | 3 +++ bin/mozilla/am.pl | 2 ++ locale/de/am | 1 + locale/en/am | 1 + 4 files changed, 7 insertions(+) diff --git a/SL/Form.pm b/SL/Form.pm index 32a82e08b..2ba19b65c 100644 --- a/SL/Form.pm +++ b/SL/Form.pm @@ -1813,6 +1813,7 @@ sub set_payment_options { $amounts{invtotal} = $self->{invtotal}; $amounts{total} = $self->{total}; } + $amounts{skonto_in_percent} = 100.0 * $self->{percent_skonto}; map { $amounts{$_} = $self->parse_amount($myconfig, $amounts{$_}) } keys %amounts; @@ -1866,6 +1867,8 @@ sub set_payment_options { map { $self->{payment_terms} =~ s/<%${_}%>/$formatted_amounts{$_}/g; } keys %formatted_amounts; + $self->{skonto_in_percent} = $formatted_amounts{skonto_in_percent}; + $main::lxdebug->leave_sub(); } diff --git a/bin/mozilla/am.pl b/bin/mozilla/am.pl index 1700b754f..a1e227fa8 100644 --- a/bin/mozilla/am.pl +++ b/bin/mozilla/am.pl @@ -2531,6 +2531,8 @@ sub payment_header { "with discount") . qq|
  • | . $locale->text("<%skonto_amount%> -- The deductible amount") +. qq|
  • +
  • | . $locale->text("<%skonto_in_percent%> -- The discount in percent") . qq|
  • | . $locale->text("<%total%> -- Amount payable") . qq|
  • diff --git a/locale/de/am b/locale/de/am index 06eb1308c..c4e043aa6 100644 --- a/locale/de/am +++ b/locale/de/am @@ -10,6 +10,7 @@ $self->{texts} = { '<%netto_date%> -- Date the payment is due in full' => '<%netto_date%> -- Das Datum, bis die Rechnung in voller Höhe bezahlt werden muss', '<%skonto_amount%> -- The deductible amount' => '<%skonto_amount%> -- Der abziehbare Skontobetrag', '<%skonto_date%> -- Date the payment is due with discount' => '<%skonto_date%> -- Das Datum, bis die Rechnung unter Abzug von Skonto bezahlt werden kann', + '<%skonto_in_percent%> -- The discount in percent' => '<%skonto_in_percent%> -- Skonto in Prozent', '<%terms_netto%> -- The number of days for full payment' => '<%terms_netto%> -- Die Anzahl Tage, bis die Rechnung in voller Höhe bezahlt werden muss', '<%total%> -- Amount payable' => '<%total%> -- Noch zu bezahlender Betrag', '<%total_wo_skonto%> -- Amount payable less discount' => '<%total_wo_skonto%> -- Noch zu bezahlender Betrag abzüglich Skonto', diff --git a/locale/en/am b/locale/en/am index b9937cd98..5c02a9625 100644 --- a/locale/en/am +++ b/locale/en/am @@ -10,6 +10,7 @@ $self->{texts} = { '<%netto_date%> -- Date the payment is due in full' => '<%netto_date%> -- Date the payment is due in full', '<%skonto_amount%> -- The deductible amount' => '<%skonto_amount%> -- The deductible amount', '<%skonto_date%> -- Date the payment is due with discount' => '<%skonto_date%> -- Date the payment is due with discount', + '<%skonto_in_percent%> -- The discount in percent' => '<%skonto_in_percent%> -- The discount in percent', '<%terms_netto%> -- The number of days for full payment' => '<%terms_netto%> -- The number of days for full payment', '<%total%> -- Amount payable' => '<%total%> -- Amount payable', '<%total_wo_skonto%> -- Amount payable less discount' => '<%total_wo_skonto%> -- Amount payable less discount', -- 2.20.1