]> wagnertech.de Git - mfinanz.git/blobdiff - SL/Form.pm
In allen Einkaufs- und Verkaufsmasken die Drop-Down-Box für die Steuerzone bei jedem...
[mfinanz.git] / SL / Form.pm
index 252c4c159dcd7016346ccc34ee81d6a0c09569dc..98b2a4e4d6e1e5cd2631bb30e7016a5175fe0f57 100644 (file)
@@ -1517,6 +1517,20 @@ sub _get_taxcharts {
   $main::lxdebug->leave_sub();
 }
 
+sub _get_taxzones {
+  $main::lxdebug->enter_sub();
+
+  my ($self, $dbh, $key) = @_;
+
+  $key = "all_taxzones" unless ($key);
+
+  my $query = qq|SELECT * FROM tax_zones ORDER BY id|;
+
+  $self->{$key} = selectall_hashref_query($self, $dbh, $query);
+
+  $main::lxdebug->leave_sub();
+}
+
 sub _get_employees {
   $main::lxdebug->enter_sub();
 
@@ -1597,6 +1611,10 @@ sub get_lists {
     $self->_get_taxcharts($dbh, $params{"taxcharts"});
   }
 
+  if ($params{"taxzones"}) {
+    $self->_get_taxzones($dbh, $params{"taxzones"});
+  }
+
   if ($params{"employees"}) {
     $self->_get_employees($dbh, $params{"employees"});
   }
@@ -1870,10 +1888,6 @@ sub create_links {
   $query = qq|SELECT id, taxkey, taxdescription FROM tax|;
   $self->{TAXKEY} = selectall_hashref_query($self, $dbh, $query);
 
-  # get tax zones
-  $query = qq|SELECT id, description FROM tax_zones|;
-  $self->{TAXZONE} = selectall_hashref_query($self, $dbh, $query);
-
   if (($module eq "AP") || ($module eq "AR")) {
     # get tax rates and description
     $query = qq|SELECT * FROM tax|;