X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/90daea72226506cd9f797ba2bfd7d3c39e19fe3e..451843cf750b655eb2678de12c369af74bca9867:/SL/IC.pm diff --git a/SL/IC.pm b/SL/IC.pm index aaae3491f..ac9547aab 100644 --- a/SL/IC.pm +++ b/SL/IC.pm @@ -811,6 +811,7 @@ sub all_parts { lastcost => ' ', factor => 'pfac.', 'SUM(ioi.qty)' => ' ', + description => 'p.', ); my %renamed_columns = ( @@ -818,8 +819,6 @@ sub all_parts { 'SUM(ioi.qty)' => 'soldtotal', ); - my %joins_needed; - if (($form->{searchitems} eq 'assembly') && $form->{l_lastcost}) { @simple_l_switches = grep { $_ ne 'lastcost' } @simple_l_switches; } @@ -830,6 +829,7 @@ sub all_parts { my @where_tokens = qw(1=1); my @group_tokens = (); my @bind_vars = (); + my %joins_needed = (); # special case transdate if (grep { $form->{$_} } qw(transdatefrom transdateto)) { @@ -842,14 +842,10 @@ sub all_parts { } } - my %simple_filter_table_prefix = ( - description => 'p.', - ); - foreach (@simple_filters, @makemodel_filters, @invoice_oi_filters) { next unless $form->{$_}; $form->{"l_$_"} = '1'; # show the column - push @where_tokens, "$simple_filter_table_prefix{$_}$_ ILIKE ?"; + push @where_tokens, "$table_prefix{$_}$_ ILIKE ?"; push @bind_vars, "%$form->{$_}%"; }