From: Bernd Bleßmann Date: Tue, 16 Mar 2021 15:43:25 +0000 (+0100) Subject: Mahnungsbericht: Erzeugte Dokumente anzeigen -> auch Rechnungen f. Mahngebühren X-Git-Tag: kivitendo-mebil_0.1-0~9^2~431 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=b82c504347d444497367f0c8195dbbb8750f54ee;p=kivitendo-erp.git Mahnungsbericht: Erzeugte Dokumente anzeigen -> auch Rechnungen f. Mahngebühren --- diff --git a/bin/mozilla/dn.pl b/bin/mozilla/dn.pl index 8f8efc5b6..ec46a4788 100644 --- a/bin/mozilla/dn.pl +++ b/bin/mozilla/dn.pl @@ -448,9 +448,14 @@ sub show_dunning { } if ($::instance_conf->get_doc_storage) { - my @files = SL::File->get_all_versions(object_id => $ref->{id}, - object_type => 'dunning' . $ref->{dunning_level}, - file_type => 'document',); + # object_types dunning1-dunning3 are the dunnings for the according levels. + my @files = SL::File->get_all_versions(object_id => $ref->{id}, + object_type => 'dunning' . $ref->{dunning_level}, + file_type => 'document',); + # object_type dunning is the dunning invoice with the fees. + push @files, SL::File->get_all_versions(object_id => $ref->{id}, + object_type => 'dunning', + file_type => 'document',); if (scalar @files) { my $html = join '
', map { SL::Presenter::FileObject::file_object($_) } @files; my $text = join "\n", map { $_->file_name } @files;