Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 83560c63

Von Bernd Blessmann vor mehr als 13 Jahren hinzugefügt

  • ID 83560c6383fec7a354753f3187c3677471ba8f06
  • Vorgänger b5f4fd07
  • Nachfolger a9937c85

Warengruppe als Dropdown bei Stammdaten/Berichte/Waren

Unterschiede anzeigen:

SL/IC.pm
911 911
    }
912 912
  }
913 913

  
914
  if ($form->{"partsgroup_id"}) {
915
    $form->{"l_partsgroup"} = '1'; # show the column
916
    push @where_tokens, "pg.id = ?";
917
    push @bind_vars, $form->{"partsgroup_id"};
918
  }
919

  
914 920
  foreach (@like_filters) {
915 921
    next unless $form->{$_};
916 922
    $form->{"l_$_"} = '1'; # show the column
bin/mozilla/ic.pl
115 115

  
116 116
  $form->header;
117 117

  
118
  $form->get_lists('partsgroup'    => 'ALL_PARTSGROUPS');
118 119
  print $form->parse_html_template('ic/search', { %is_xyz,
119
                                                  dateformat => $myconfig{dateformat}, });
120
                                                  dateformat => $myconfig{dateformat}, 
121
                                                  limit => $myconfig{vclimit}, });
120 122

  
121 123
  $lxdebug->leave_sub();
122 124
}    #end search()
......
1103 1105
    no_sn_joins  => [ qw(bought sold) ],
1104 1106
  );
1105 1107

  
1108
  # get name of partsgroup if id is given
1109
  my $pg_name;
1110
  if ($form->{partsgroup_id}) {
1111
    my $pg = SL::DB::PartsGroup->new(id => $form->{partsgroup_id})->load;
1112
    $pg_name = $pg->{'partsgroup'};
1113
  }
1114

  
1106 1115
  # these strings get displayed at the top of the results to indicate the user which switches were used
1107 1116
  my %optiontexts = (
1108 1117
    active        => $locale->text('Active'),
......
1120 1129
    transdateto   => $locale->text('To (time)')  . " " . $locale->date(\%myconfig, $form->{transdateto}, 1),
1121 1130
    partnumber    => $locale->text('Part Number')      . ": '$form->{partnumber}'",
1122 1131
    partsgroup    => $locale->text('Group')            . ": '$form->{partsgroup}'",
1132
    partsgroup_id => $locale->text('Group')            . ": '$pg_name'",
1123 1133
    serialnumber  => $locale->text('Serial Number')    . ": '$form->{serialnumber}'",
1124 1134
    description   => $locale->text('Part Description') . ": '$form->{description}'",
1125 1135
    make          => $locale->text('Make')             . ": '$form->{make}'",
......
1131 1141
  );
1132 1142

  
1133 1143
  my @itemstatus_keys = qw(active obsolete orphaned onhand short);
1134
  my @callback_keys   = qw(onorder ordered rfq quoted bought sold partnumber partsgroup serialnumber description make model
1144
  my @callback_keys   = qw(onorder ordered rfq quoted bought sold partnumber partsgroup partsgroup_id serialnumber description make model
1135 1145
                           drawing microfiche l_soldtotal l_deliverydate transdatefrom transdateto ean);
1136 1146

  
1137 1147
  # calculate dependencies
templates/webpages/ic/search.html
37 37

  
38 38
      <tr>
39 39
       <th align="right" nowrap>[% 'Group' | $T8 %]</th>
40
       <td><input name="partsgroup" size="20"></td>
40
       <td>
41
         [%- INCLUDE generic/multibox.html
42
           name          = 'partsgroup',
43
           select_name   = 'partsgroup_id',
44
           DATA          = ALL_PARTSGROUPS,
45
           show_empty    = 1,
46
           id_key        = 'id',
47
           label_key     = 'partsgroup',
48
           style         = 'width:250px',
49
           limit         = limit,
50
           allow_textbox = 1
51
         -%]
52
       </td>
41 53
       <th align="right" nowrap>[% 'Serial Number' | $T8 %]</th> <td><input name="serialnumber" size="20"></td>
42 54
      </tr>
43 55

  

Auch abrufbar als: Unified diff