Mailer.pm wurde umgebaut, vergessene Caller geändert
authorJan Büren <jan@kivitendo-premium.de>
Mon, 25 Sep 2017 14:58:30 +0000 (16:58 +0200)
committerJan Büren <jan@kivitendo-premium.de>
Mon, 25 Sep 2017 14:58:30 +0000 (16:58 +0200)
Behebt #303, ggf. noch weitere Stellen betroffen.

SL/Controller/Letter.pm
SL/DN.pm

index 9efca36..780d7f9 100644 (file)
@@ -241,8 +241,8 @@ sub action_print_letter {
       my $signature        = $::myconfig{signature};
       $mail->{$_}          = $params{email}->{$_} for qw(to cc subject message bcc);
       $mail->{from}        = qq|"$::myconfig{name}" <$::myconfig{email}>|;
-      $mail->{attachments} = [{ filename => $result{file_name},
-                                name     => $params{email}->{attachment_filename} }];
+      $mail->{attachments} = [{ path => $result{file_name},
+                                name => $params{email}->{attachment_filename} }];
       $mail->{message}    .=  "\n-- \n$signature";
       $mail->{message}     =~ s/\r//g;
 
index adb58b7..cf800da 100644 (file)
--- a/SL/DN.pm
+++ b/SL/DN.pm
@@ -904,7 +904,7 @@ sub print_dunning {
   delete $form->{tmpfile};
 
   push @{ $form->{DUNNING_PDFS} }, $filename;
-  push @{ $form->{DUNNING_PDFS_EMAIL} }, { 'filename' => "${spool}/$filename",
+  push @{ $form->{DUNNING_PDFS_EMAIL} }, { 'path' => "${spool}/$filename",
                                            'name'     => $form->get_formname_translation('dunning') . "_${dunning_id}.pdf" };
 
   $form->get_employee_data('prefix' => 'employee', 'id' => $form->{employee_id});