From 6c7fdf43ade0e2e5cc82eca47eeb850424b896b1 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Thu, 1 Oct 2015 13:36:06 +0200 Subject: [PATCH] Debitorenbuchungen: aktuellen Mahnstatus anzeigen Der Mahnstatus wird nun analog zu Verkaufsrechnungen angezeigt. --- bin/mozilla/ar.pl | 2 ++ templates/webpages/ar/form_header.html | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/bin/mozilla/ar.pl b/bin/mozilla/ar.pl index b1421d6ad..e299d90a9 100644 --- a/bin/mozilla/ar.pl +++ b/bin/mozilla/ar.pl @@ -40,6 +40,7 @@ use SL::FU; use SL::IS; use SL::PE; use SL::DB::Default; +use SL::DB::Invoice; use SL::ReportGenerator; require "bin/mozilla/arap.pl"; @@ -149,6 +150,7 @@ sub create_links { my %myconfig = %main::myconfig; $form->create_links("AR", \%myconfig, "customer"); + $form->{invoice_obj} = $form->{id} ? SL::DB::Invoice->new(id => $form->{id})->load : undef; my %saved; if (!$params{dont_save}) { diff --git a/templates/webpages/ar/form_header.html b/templates/webpages/ar/form_header.html index ee3aa5cd3..03fb634fa 100644 --- a/templates/webpages/ar/form_header.html +++ b/templates/webpages/ar/form_header.html @@ -50,6 +50,24 @@ [% L.hidden_tag('customer_id', customer_id) %] [% L.hidden_tag('terms', terms) %] +[%- IF max_dunning_level || invoice_obj.dunning_config_id %] + + [% LxERP.t8("Dunning status") %] + + [% IF invoice_obj.dunning_config_id %] + [% LxERP.t8("This invoice's dunning level: #1", invoice_obj.dunning_config.dunning_description) %] + [% IF max_dunning_level %]
[% END %] + [% END %] + [% IF max_dunning_level %] + + [% LxERP.t8("Customer's current maximum dunning level: #1", max_dunning_level) %] +
+ [% LxERP.t8("Dunned open amount: #1", LxERP.format_amount(dunning_amount, 2)) %] +
+ [% END %] + + +[%- END %] -- 2.20.1