- my $sth =
- $dbh->prepare(
- "Select itemtype,description from itemtypes order by description");
- $sth->execute;
- my @itemtype;
- my %itemtypes;
- push @itemtype, "";
- $itemtypes{''} = "";
- while ( my ( $value, $lib ) = $sth->fetchrow_array ) {
- push @itemtype, $value;
- $itemtypes{$value} = $lib;
- }
-
- my $CGIitemtype = CGI::scrolling_list(
- -name => 'value',
- -values => \@itemtype,
- -labels => \%itemtypes,
- -size => 1,
- -multiple => 0
- );
- $sth->finish;
-
- my @branchloop;
- my @select_branch;
- my %select_branches;
- my $branches = GetBranches;
- push @select_branch, "";
- $select_branches{''} = "";
- foreach my $thisbranch ( keys %$branches ) {
- push @select_branch, $branches->{$thisbranch}->{'branchcode'};
- $select_branches{ $branches->{$thisbranch}->{'branchcode'} } =
- $branches->{$thisbranch}->{'branchname'};
- }
- my $CGIbranch = CGI::scrolling_list(
- -name => 'value',
- -values => \@select_branch,
- -labels => \%select_branches,
- -size => 1,
- -multiple => 0
- );
- $sth->finish;
-
- my $req =
- $dbh->prepare(
-"select distinctrow left(publishercode,45) from biblioitems order by publishercode"
- );
- $req->execute;
- my @select;
- push @select, "";
- while ( my ($value) = $req->fetchrow ) {
- push @select, $value;
- }
- my $CGIpublisher = CGI::scrolling_list(
- -name => 'value',
- -id => 'publisher',
- -values => \@select,
- -size => 1,
- -multiple => 0
- );
-
-# my $sth=$dbh->prepare("select description,itemtype from itemtypes order by description");
-# $sth->execute;
-# while (my ($description,$itemtype) = $sth->fetchrow) {
-# $classlist.="<option value=\"$itemtype\">$description</option>\n";
-# }
-# $sth->finish;
-
- my @itemtypes = C4::ItemType->all;