Bug 6351: Unable to delete branch-specific circulation rule
[koha.git] / opac / opac-MARCdetail.pl
index 1a9dc34..8e492aa 100755 (executable)
@@ -1,6 +1,7 @@
 #!/usr/bin/perl
 
 # Copyright 2000-2002 Katipo Communications
+# Parts copyright 2010 BibLibre
 #
 # This file is part of Koha.
 #
@@ -71,7 +72,7 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
         template_name   => "opac-MARCdetail.tmpl",
         query           => $query,
         type            => "opac",
-        authnotrequired => 1,
+        authnotrequired => ( C4::Context->preference("OpacPublic") ? 1 : 0 ),
         debug           => 1,
     }
 );
@@ -193,7 +194,7 @@ for ( my $tabloop = 0 ; $tabloop <= 10 ; $tabloop++ ) {
             undef @subfields_data;
         }
     }
-    $template->param( $tabloop . "XX" => \@loop_data );
+    $template->param( "tab" . $tabloop . "XX" => \@loop_data );
 }