From 0c0d58c4490d00b764df71c42f562bee1f9ff252 Mon Sep 17 00:00:00 2001 From: oleonard Date: Thu, 27 Apr 2006 16:23:34 +0000 Subject: [PATCH] Hiding option to add to existing virtual shelves if there are no existing virtual shelves (thanks Chris!) --- .../opac-tmpl/npl/en/opac-addbookbybiblionumber.tmpl | 4 ++-- opac/opac-addbookbybiblionumber.pl | 8 +++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/koha-tmpl/opac-tmpl/npl/en/opac-addbookbybiblionumber.tmpl b/koha-tmpl/opac-tmpl/npl/en/opac-addbookbybiblionumber.tmpl index 8f1514ae84..b6339cc8a4 100644 --- a/koha-tmpl/opac-tmpl/npl/en/opac-addbookbybiblionumber.tmpl +++ b/koha-tmpl/opac-tmpl/npl/en/opac-addbookbybiblionumber.tmpl @@ -1,13 +1,13 @@ Catalog -- Add to My Virtual Shelf

Add by to a Virtual Shelf

-
+
Select a Virtual Shelf:
-

...or...

+

...or...

diff --git a/opac/opac-addbookbybiblionumber.pl b/opac/opac-addbookbybiblionumber.pl index 6a875ec553..3aad06ba20 100755 --- a/opac/opac-addbookbybiblionumber.pl +++ b/opac/opac-addbookbybiblionumber.pl @@ -65,11 +65,14 @@ if ($shelfnumber) { $shelvesloop{$element} = $shelflist->{$element}->{'shelfname'}; } - my $CGIbookshelves=CGI::scrolling_list( -name => 'shelfnumber', + my $CGIbookshelves; + if (@shelvesloop > 0){ + $CGIbookshelves=CGI::scrolling_list( -name => 'shelfnumber', -values => \@shelvesloop, -labels => \%shelvesloop, -size => 1, -multiple => 0 ); + } $template->param(biblionumber => $biblionumber, title => $biblios[0]->{'title'}, @@ -88,6 +91,9 @@ $template->param(biblionumber => $biblionumber, output_html_with_http_headers $query, $cookie, $template->output; } # $Log$ +# Revision 1.1.2.6 2006/04/27 16:23:34 oleonard +# Hiding option to add to existing virtual shelves if there are no existing virtual shelves (thanks Chris!) +# # Revision 1.1.2.5 2006/03/01 22:33:25 oleonard # Enabling several new system preferences: opacreadinghistory, opaccolorstylesheet, opaclanguagesdisplay, opaclayoutstylesheet, opacsmallimage # -- 2.39.5
Add to a new Virtual Shelf: