From 26993da686d851ccaa5201ae6b42eee50166b448 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bernd=20Ble=C3=9Fmann?= Date: Fri, 12 Nov 2021 11:59:20 +0100 Subject: [PATCH] Kosmetik --- SL/Controller/Order.pm | 9 +++++---- bin/mozilla/io.pl | 9 +++++---- templates/webpages/common/_send_email_dialog.html | 2 +- 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/SL/Controller/Order.pm b/SL/Controller/Order.pm index 4cf9f614a..c19eed6c4 100644 --- a/SL/Controller/Order.pm +++ b/SL/Controller/Order.pm @@ -425,12 +425,13 @@ sub action_save_and_show_email_dialog { $email_form->{js_send_function} = 'kivi.Order.send_email()'; my %files = $self->get_files_for_email_dialog(); + $self->{all_employees} = SL::DB::Manager::Employee->get_all(query => [ deleted => 0 ]); my $dialog_html = $self->render('common/_send_email_dialog', { output => 0 }, - email_form => $email_form, - show_bcc => $::auth->assert('email_bcc', 'may fail'), - FILES => \%files, - is_customer => $self->cv eq 'customer', + email_form => $email_form, + show_bcc => $::auth->assert('email_bcc', 'may fail'), + FILES => \%files, + is_customer => $self->cv eq 'customer', ALL_EMPLOYEES => $self->{all_employees}, ); diff --git a/bin/mozilla/io.pl b/bin/mozilla/io.pl index 89e40d0e5..6d1572b15 100644 --- a/bin/mozilla/io.pl +++ b/bin/mozilla/io.pl @@ -2114,6 +2114,7 @@ sub show_sales_purchase_email_dialog { } $::form->{all_employees} = SL::DB::Manager::Employee->get_all(query => [ deleted => 0 ]); + my $email_form = { to => $email, cc => $email_cc, @@ -2125,10 +2126,10 @@ sub show_sales_purchase_email_dialog { my %files = _get_files_for_email_dialog(); my $html = $::form->parse_html_template("common/_send_email_dialog", { - email_form => $email_form, - show_bcc => $::auth->assert('email_bcc', 'may fail'), - FILES => \%files, - is_customer => $::form->{vc} eq 'customer', + email_form => $email_form, + show_bcc => $::auth->assert('email_bcc', 'may fail'), + FILES => \%files, + is_customer => $::form->{vc} eq 'customer', is_invoice_mail => ($record_email && $::form->{type} eq 'invoice'), ALL_EMPLOYEES => $::form->{all_employees}, }); diff --git a/templates/webpages/common/_send_email_dialog.html b/templates/webpages/common/_send_email_dialog.html index 79b984c81..e626c3510 100644 --- a/templates/webpages/common/_send_email_dialog.html +++ b/templates/webpages/common/_send_email_dialog.html @@ -43,7 +43,7 @@ [%- IF ALL_EMPLOYEES.size %] [% LxERP.t8("CC to Employee") %] - [% L.select_tag('email_form.cc_employee', ALL_EMPLOYEES, value_key='login' title_key='safe_name', with_empty=1, style=style) %] + [% L.select_tag('email_form.cc_employee', ALL_EMPLOYEES, value_key='login' title_key='safe_name', with_empty=1, style=style) %] [%- END %] -- 2.20.1