X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Far.pl;h=251c4644cb7f90a5ae6534429b1d7d3fc018b606;hb=c9902d7658d0cacdf665971b32de0e054637efd0;hp=8efd498facf17845c5b29dfe251c07676619e99f;hpb=4bbb5dbe9a272bc31d5f059b3ece3e230c2a6642;p=kivitendo-erp.git diff --git a/bin/mozilla/ar.pl b/bin/mozilla/ar.pl index 8efd498fa..251c4644c 100644 --- a/bin/mozilla/ar.pl +++ b/bin/mozilla/ar.pl @@ -982,9 +982,13 @@ sub update { $form->{invdate} = $form->{transdate}; - my %saved_variables = map +( $_ => $form->{$_} ), qw(AR AR_amount_1 taxchart_1); - + my %saved_variables = map +( $_ => $form->{$_} ), qw(AR AR_amount_1 taxchart_1 oldcustomer); + &check_name("customer"); + + # check_name ruft get_customer auf, oldcustomer wird überschrieben, daher wird dies vorher gemerkt + # get_customer holt Bemerkungen als intnotes, für Debitorenbuchungen gibt es aber nur das Feld notes + $form->{notes} = $form->{intnotes} if $saved_variables{oldcustomer} ne $form->{customer}; $form->{AR} = $saved_variables{AR}; if ($saved_variables{AR_amount_1} =~ m/.--./) { @@ -1275,13 +1279,20 @@ sub search { $form->{title} = $locale->text('AR Transactions'); $form->{jsscript} = 1; - $form->get_lists("projects" => { "key" => "ALL_PROJECTS", "all" => 1 }, - "departments" => "ALL_DEPARTMENTS", - "customers" => "ALL_VC"); + # Auch in Rechnungsübersicht nach Kundentyp filtern - jan + $form->get_lists("projects" => { "key" => "ALL_PROJECTS", "all" => 1 }, + "departments" => "ALL_DEPARTMENTS", + "customers" => "ALL_VC", + "employees" => "ALL_EMPLOYEES", + "salesmen" => "ALL_SALESMEN", + "business_types" => "ALL_BUSINESS_TYPES"); + $form->{SHOW_BUSINESS_TYPES} = scalar @{ $form->{ALL_BUSINESS_TYPES} } > 0; # constants and subs for template $form->{jsscript} = 1; $form->{vc_keys} = sub { "$_[0]->{name}--$_[0]->{id}" }; + $form->{employee_labels} = sub { $_[0]->{"name"} || $_[0]->{"login"} }; + $form->{salesman_labels} = $form->{employee_labels}; $form->header; print $form->parse_html_template('ar/search', { %myconfig }); @@ -1433,6 +1444,7 @@ sub ar_transactions { 'attachment_basename' => $locale->text('invoice_list') . strftime('_%Y%m%d', localtime time), ); $report->set_options_from_form(); + $locale->set_numberformat_wo_thousands_separator(\%myconfig) if lc($report->{options}->{output_format}) eq 'csv'; # add sort and escape callback, this one we use for the add sub $form->{callback} = $href .= "&sort=$form->{sort}";