From 2b37ad3a147be6cf6c904327c3a589302bf0dc54 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20B=C3=BCren?= Date: Sat, 30 Sep 2017 10:02:09 +0200 Subject: [PATCH] Abteilungs-Dropdown konsequent alphabetisch vorsortieren $dep->get_all ==> $dep->get_all_sorted --- bin/mozilla/ap.pl | 2 +- bin/mozilla/ar.pl | 4 ++-- bin/mozilla/datev.pl | 2 +- bin/mozilla/do.pl | 4 ++-- bin/mozilla/gl.pl | 8 ++++---- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/bin/mozilla/ap.pl b/bin/mozilla/ap.pl index 52c3055a7..f13b8d251 100644 --- a/bin/mozilla/ap.pl +++ b/bin/mozilla/ap.pl @@ -413,7 +413,7 @@ sub form_header { @{ $form->{ALL_CHARTS} } ); - $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; my %project_labels = (); foreach my $item (@{ $form->{"ALL_PROJECTS"} }) { diff --git a/bin/mozilla/ar.pl b/bin/mozilla/ar.pl index 20d29fc1e..089446bda 100644 --- a/bin/mozilla/ar.pl +++ b/bin/mozilla/ar.pl @@ -310,7 +310,7 @@ sub create_links { # currencies $form->{defaultcurrency} = $form->get_default_currency(\%myconfig); - $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; # build the popup menus $form->{taxincluded} = ($form->{id}) ? $form->{taxincluded} : "checked"; @@ -371,7 +371,7 @@ sub form_header { "taxcharts" => { "key" => "ALL_TAXCHARTS", "module" => "AR" },); - $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; $_->{link_split} = { map { $_ => 1 } split/:/, $_->{link} } for @{ $form->{ALL_CHARTS} }; diff --git a/bin/mozilla/datev.pl b/bin/mozilla/datev.pl index 32032e514..e5c048b66 100644 --- a/bin/mozilla/datev.pl +++ b/bin/mozilla/datev.pl @@ -77,7 +77,7 @@ sub export_bewegungsdaten { setup_datev_export2_action_bar(); $::form->header; - $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; print $::form->parse_html_template('datev/export_bewegungsdaten'); $::lxdebug->leave_sub; diff --git a/bin/mozilla/do.pl b/bin/mozilla/do.pl index 66c1c95aa..87a00205b 100644 --- a/bin/mozilla/do.pl +++ b/bin/mozilla/do.pl @@ -412,7 +412,7 @@ sub form_header { $form->get_lists("price_factors" => "ALL_PRICE_FACTORS", "business_types" => "ALL_BUSINESS_TYPES", ); - $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; # Projects my @old_project_ids = uniq grep { $_ } map { $_ * 1 } ($form->{"globalproject_id"}, map { $form->{"project_id_$_"} } 1..$form->{"rowcount"}); @@ -647,7 +647,7 @@ sub search { "all" => 1 }, "business_types" => "ALL_BUSINESS_TYPES"); $form->{ALL_EMPLOYEES} = SL::DB::Manager::Employee->get_all_sorted(query => [ deleted => 0 ]); - $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; $form->{title} = $locale->text('Delivery Orders'); setup_do_search_action_bar(); diff --git a/bin/mozilla/gl.pl b/bin/mozilla/gl.pl index 593209a23..519351a5f 100644 --- a/bin/mozilla/gl.pl +++ b/bin/mozilla/gl.pl @@ -224,7 +224,7 @@ sub add { $form->{credit} = 0; $form->{tax} = 0; - $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; $form->{show_details} = $myconfig{show_form_details} unless defined $form->{show_details}; @@ -245,7 +245,7 @@ sub prepare_transaction { $form->{amount} = $form->format_amount(\%myconfig, $form->{amount}, 2); - $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; my $i = 1; my $tax = 0; @@ -336,7 +336,7 @@ sub search { projects => { key => "ALL_PROJECTS", all => 1 }, ); $::form->{ALL_EMPLOYEES} = SL::DB::Manager::Employee->get_all_sorted(query => [ deleted => 0 ]); - $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; setup_gl_search_action_bar(); @@ -1085,7 +1085,7 @@ sub form_header { # we cannot book on charttype header @{ $::form->{ALL_CHARTS} } = grep { $_->{charttype} ne 'H' } @{ $::form->{ALL_CHARTS} }; - $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all; + $::form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted; my $title = $::form->{title}; $::form->{title} = $::locale->text("$title General Ledger Transaction"); -- 2.20.1