From: Moritz Bunkus Date: Fri, 4 Aug 2017 12:42:52 +0000 (+0200) Subject: E-Mail-Dialog: Vorbelegung vom Kunden/Lieferanten, wenn Ansprechperson keine E-Mail hat X-Git-Tag: release-3.5.4~917 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=103d03fb414002f186353c48e41eeecd76d1e31d;p=kivitendo-erp.git E-Mail-Dialog: Vorbelegung vom Kunden/Lieferanten, wenn Ansprechperson keine E-Mail hat Siehe #263. --- diff --git a/bin/mozilla/io.pl b/bin/mozilla/io.pl index eab839857..1fd47c877 100644 --- a/bin/mozilla/io.pl +++ b/bin/mozilla/io.pl @@ -1969,7 +1969,9 @@ sub show_sales_purchase_email_dialog { my $email = ''; if ($::form->{cp_id}) { $email = SL::DB::Contact->load_cached($::form->{cp_id})->cp_email; - } elsif ($::form->{vc} && $::form->{vc_id}) { + } + + if (!$email && $::form->{vc} && $::form->{vc_id}) { $email = SL::DB::Customer->load_cached($::form->{vc_id})->email if 'customer' eq $::form->{vc}; $email = SL::DB::Vendor ->load_cached($::form->{vc_id})->email if 'vendor' eq $::form->{vc}; }