[Koha-bugs] [Bug 33244] Do not show lists in OPAC if OpacPublic is disabled

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Oct 25 23:20:06 CEST 2023


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33244

--- Comment #1 from jpl <data-27FC05A3CB97 at office-dateien.de> ---
Quick workaround I came up with. Works for me with Koha 22.11.10.000 Rosalie.
This will only shows the lists when a user is logged in if opacpublic is set to
false.

--- /koha/src/masthead.inc      2023-10-25 23:02:01.538423660 +0200
+++ masthead.inc                2023-10-25 23:03:45.558420570 +0200
@@ -37,6 +37,7 @@
                 [% END %]
                 <li class="divider-vertical"></li>
                 [% IF ( Koha.Preference( 'virtualshelves' ) == 1 ) %]
+                       [% IF (( Koha.Preference( 'opacpublic' ) == 0 ) && (
logged_in_user )) || ( Koha.Preference( 'opacpublic' )) %]
                     <li class="nav-item dropdown">
                         <a href="/cgi-bin/koha/opac-shelves.pl" title="Show
lists" class="nav-link dropdown-toggle" id="listsmenu" data-toggle="dropdown"
role="button" aria-label="Show dropdown with detailed list information"
aria-haspopup="true" aria-expanded="false"
                             ><i class="fa fa-list fa-icon-black"
aria-hidden="true"></i> <span class="listslabel">Lists</span>
@@ -81,6 +82,7 @@
                         </div> <!-- / .dropdown-menu -->
                     </li> <!-- / .nav-item.dropdown -->
                 [% END # / IF virtualshelves %]
+                [% END %]
             </ul> <!-- / .navbar-nav -->

             [% IF Koha.Preference( 'opacuserlogin' ) == 1 ||  Koha.Preference(
'EnableOpacSearchHistory') || Koha.Preference( 'opaclanguagesdisplay' ) %]

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list