X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fio.pl;h=0a6b861d0d6b90aaa88269fdc14b8a9dd85ad1e8;hb=edff34950b489a16a8d49d7d583479e23cb5d6c7;hp=62f16d7f3b393bd9f915df4bb3531b45c93d9d31;hpb=598383b3b6b63428fcabc5fb6e5595ec59de28e3;p=kivitendo-erp.git diff --git a/bin/mozilla/io.pl b/bin/mozilla/io.pl index 62f16d7f3..0a6b861d0 100644 --- a/bin/mozilla/io.pl +++ b/bin/mozilla/io.pl @@ -328,7 +328,7 @@ sub display_row { $ship_qty /= ( $all_units->{$form->{"unit_$i"}}->{factor} || 1 ); $column_data{ship} = $form->format_amount(\%myconfig, $form->round_amount($ship_qty, 2) * 1) . ' ' . $form->{"unit_$i"} - . $cgi->hidden(-name => "ship_$i", -value => $form->format_amount(\%myconfig, $form->{"ship_$i"}, $qty_dec)); + . $cgi->hidden(-name => "ship_$i", -value => $form->{"ship_$i"}, $qty_dec); my $ship_missing_qty = $form->{"qty_$i"} - $ship_qty; my $ship_missing_amount = $form->round_amount($ship_missing_qty * $form->{"sellprice_$i"} * (100 - $form->{"discount_$i"}) / 100 / $price_factor, 2); @@ -944,6 +944,7 @@ sub order { require SL::Controller::Order; my $c = SL::Controller::Order->new(order => $order); + $c->setup_custom_shipto_from_form($order, $::form); $c->action_edit(); $main::lxdebug->leave_sub(); @@ -1408,7 +1409,7 @@ sub print_form { # Format dates. format_dates($output_dateformat, $output_longdates, - qw(invdate orddate quodate pldate duedate reqdate transdate + qw(invdate orddate quodate pldate duedate reqdate transdate tax_point shippingdate deliverydate validitydate paymentdate datepaid transdate_oe transdate_do transdate_quo deliverydate_oe dodate employee_startdate employee_enddate @@ -2008,9 +2009,8 @@ sub _make_record { sub setup_sales_purchase_print_options { my $print_form = Form->new(''); $print_form->{printers} = SL::DB::Manager::Printer->get_all_sorted; - $print_form->{languages} = SL::DB::Manager::Language->get_all_sorted; - $print_form->{$_} = $::form->{$_} for qw(type media language_id printer_id storno formname groupitems); + $print_form->{$_} = $::form->{$_} for qw(type media printer_id storno formname groupitems); return SL::Helper::PrintOptions->get_print_options( form => $print_form, @@ -2092,11 +2092,17 @@ sub show_sales_purchase_email_dialog { $::form->{language} = $::form->get_template_language(\%::myconfig); $::form->{language} = "_" . $::form->{language}; + my %body_params = (record_email => $record_email); + if (($::form->{type} eq 'invoice') && $::form->{direct_debit}) { + $body_params{translation_type} = "preset_text_invoice_direct_debit"; + $body_params{fallback_translation_type} = "preset_text_invoice"; + } + my $email_form = { to => $email, cc => $email_cc, subject => $::form->generate_email_subject, - message => $::form->generate_email_body('record_email' => $record_email), + message => $::form->generate_email_body(%body_params), attachment_filename => $::form->generate_attachment_filename, js_send_function => 'kivi.SalesPurchase.send_email()', }; @@ -2160,8 +2166,8 @@ sub _maybe_attach_zugferd_data { $form->{TEMPLATE_DRIVER_OPTIONS}->{pdf_a} = $record->create_pdf_a_print_options(zugferd_xmp_data => $record->create_zugferd_xmp_data); $form->{TEMPLATE_DRIVER_OPTIONS}->{pdf_attachments} = [ { source => $xmlfile, - name => 'ZUGFeRD-invoice.xml', - description => $::locale->text('ZUGFeRD invoice'), + name => 'factur-x.xml', + description => $::locale->text('Factur-X/ZUGFeRD invoice'), relationship => '/Alternative', mime_type => 'text/xml', }