- # Oder Bedingungen fuer Ware Dienstleistung Erzeugnis:
- if ($form->{l_part} || $form->{l_assembly} || $form->{l_service}) {
- my @or_tokens = ();
- push @or_tokens, "p.part_type = 'service'" if $form->{l_service};
- push @or_tokens, "p.part_type = 'assembly'" if $form->{l_assembly};
- push @or_tokens, "p.part_type = 'part'" if $form->{l_part};
- push @where_tokens, join ' OR ', map { "($_)" } @or_tokens;
- }
- else {
- # gar keine Teile
- push @where_tokens, q|'F' = 'T'|;
- }
-
- if ( $form->{classification_id} > 0 ) {
- push @where_tokens, "p.classification_id = ?";
- push @bind_vars, $form->{classification_id};
+ for ($form->{searchitems}) {
+ push @where_tokens, "p.part_type = 'part'" if /part/;
+ push @where_tokens, "p.part_type = 'service'" if /service/;
+ push @where_tokens, "p.part_type = 'assembly'" if /assembly/;