$main::lxdebug->leave_sub();
}
-sub _get_taxcharts {
- $main::lxdebug->enter_sub();
-
- my ($self, $dbh, $params) = @_;
-
- my $key = "all_taxcharts";
- my @where;
-
- if (ref $params eq 'HASH') {
- $key = $params->{key} if ($params->{key});
- if ($params->{module} eq 'AR') {
- push @where, 'chart_categories ~ \'[ACILQ]\'';
-
- } elsif ($params->{module} eq 'AP') {
- push @where, 'chart_categories ~ \'[ACELQ]\'';
- }
-
- } elsif ($params) {
- $key = $params;
- }
-
- my $where = @where ? ' WHERE ' . join(' AND ', map { "($_)" } @where) : '';
-
- my $query = qq|SELECT * FROM tax $where ORDER BY taxkey, rate|;
-
- $self->{$key} = selectall_hashref_query($self, $dbh, $query);
-
- $main::lxdebug->leave_sub();
-}
-
sub _get_taxzones {
$main::lxdebug->enter_sub();
$self->_get_charts($dbh, $params{"charts"});
}
- if ($params{"taxcharts"}) {
- $self->_get_taxcharts($dbh, $params{"taxcharts"});
- }
-
if ($params{"taxzones"}) {
$self->_get_taxzones($dbh, $params{"taxzones"});
}
"old_id" => \@old_project_ids },
"charts" => { "key" => "ALL_CHARTS",
"transdate" => $form->{transdate} },
- "taxcharts" => { "key" => "ALL_TAXCHARTS",
- "module" => "AR" },);
+ );
$form->{ALL_DEPARTMENTS} = SL::DB::Manager::Department->get_all_sorted;