diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/addbybiblionumber.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/addbybiblionumber.tmpl
index 646b55b12a..19148946c8 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/addbybiblionumber.tmpl
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/addbybiblionumber.tmpl
@@ -2,7 +2,7 @@
Koha › Add to Virtual Shelf
@@ -11,42 +11,44 @@
-
Add
+Add
by
to a virtual shelf
-
+
-
-
...or...
+
...or...
+
diff --git a/virtualshelves/addbybiblionumber.pl b/virtualshelves/addbybiblionumber.pl
index 00a5f81032..456f51edcd 100755
--- a/virtualshelves/addbybiblionumber.pl
+++ b/virtualshelves/addbybiblionumber.pl
@@ -100,7 +100,7 @@ else { # this shelf doesn't already exist.
push( @shelvesloop, $element );
$shelvesloop{$element} = $shelflist->{$element}->{'shelfname'};
}
-
+ if(@shelvesloop gt 0){
my $CGIvirtualshelves = CGI::scrolling_list(
-name => 'shelfnumber',
-values => \@shelvesloop,
@@ -109,12 +109,15 @@ else { # this shelf doesn't already exist.
-tabindex => '',
-multiple => 0
);
+ $template->param(
+ CGIvirtualshelves => $CGIvirtualshelves,
+ );
+ }
$template->param(
biblionumber => $biblionumber,
title => $biblios[0]->{'title'},
author => $biblios[0]->{'author'},
- CGIvirtualshelves => $CGIvirtualshelves,
);
output_html_with_http_headers $query, $cookie, $template->output;