|
Lines 44-92
Link Here
|
| 44 |
[% END %] |
44 |
[% END %] |
| 45 |
<li class="divider-vertical"></li> |
45 |
<li class="divider-vertical"></li> |
| 46 |
[% IF ( Koha.Preference( 'virtualshelves' ) == 1 ) %] |
46 |
[% IF ( Koha.Preference( 'virtualshelves' ) == 1 ) %] |
| 47 |
<li class="nav-item dropdown"> |
47 |
[% IF Koha.Preference( 'opacuserlogin' ) == 1 || some_public_shelves.count > 0 %] |
| 48 |
<a href="/cgi-bin/koha/opac-shelves.pl" title="Show lists" class="nav-link dropdown-toggle" id="listsmenu" data-bs-toggle="dropdown" role="button" aria-label="Lists" aria-haspopup="true" aria-expanded="false" |
48 |
<li class="nav-item dropdown"> |
| 49 |
><i class="fa fa-list fa-fw fa-icon-black" aria-hidden="true"></i> <span class="listslabel">Lists</span> |
49 |
<a href="/cgi-bin/koha/opac-shelves.pl" title="Show lists" class="nav-link dropdown-toggle" id="listsmenu" data-bs-toggle="dropdown" role="button" aria-label="Show dropdown with detailed list information" aria-haspopup="true" aria-expanded="false" |
| 50 |
</a> |
50 |
><i class="fa fa-list fa-fw fa-icon-black" aria-hidden="true"></i> <span class="listslabel">Lists</span> |
| 51 |
<div aria-labelledby="listsmenu" role="menu" class="dropdown-menu"> |
51 |
</a> |
| 52 |
[% IF some_public_shelves.count %] |
52 |
<div aria-labelledby="listsmenu" role="menu" class="dropdown-menu"> |
| 53 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=1" tabindex="-1" role="menuitem"><strong>Public lists</strong></a> |
53 |
[% IF some_public_shelves.count %] |
| 54 |
[% SET number_of_public_shelves = 0 %] |
54 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=1" tabindex="-1" role="menuitem"><strong>Public lists</strong></a> |
| 55 |
[% FOREACH s IN some_public_shelves %] |
55 |
[% SET number_of_public_shelves = 0 %] |
| 56 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=view&shelfnumber=[% s.shelfnumber | uri %]&sortfield=[% s.sortfield | uri %]" tabindex="-1" role="menuitem">[% s.shelfname | html %]</a> |
56 |
[% FOREACH s IN some_public_shelves %] |
| 57 |
[% SET number_of_public_shelves = number_of_public_shelves + 1 %] |
57 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=view&shelfnumber=[% s.shelfnumber | uri %]&sortfield=[% s.sortfield | uri %]" tabindex="-1" role="menuitem">[% s.shelfname | html %]</a> |
| 58 |
[% IF number_of_public_shelves >= 10 %][% LAST %][% END %] |
58 |
[% SET number_of_public_shelves = number_of_public_shelves + 1 %] |
|
|
59 |
[% IF number_of_public_shelves >= 10 %][% LAST %][% END %] |
| 60 |
[% END %] |
| 61 |
[% IF some_public_shelves > 10 %] |
| 62 |
<a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=1" tabindex="-1" role="menuitem">View all</a> |
| 63 |
[% END %] |
| 59 |
[% END %] |
64 |
[% END %] |
| 60 |
[% IF some_public_shelves > 10 %] |
65 |
[% IF Koha.Preference( 'opacuserlogin' ) == 1 && some_public_shelves.count > 0 %] |
| 61 |
<a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=1" tabindex="-1" role="menuitem">View all</a> |
66 |
<div class="dropdown-divider"></div> |
| 62 |
[% END %] |
67 |
[% END %] |
| 63 |
[% END %] |
68 |
[% IF Koha.Preference( 'opacuserlogin' ) == 1 %] |
| 64 |
[% IF some_public_shelves.count > 0 %] |
69 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=0" tabindex="-1" role="menuitem"><strong>Your lists</strong></a> |
| 65 |
<div class="dropdown-divider"></div> |
70 |
[% IF loggedinusername %] |
| 66 |
[% END %] |
71 |
[% IF some_private_shelves.count %] |
| 67 |
[% IF Koha.Preference( 'opacuserlogin' ) == 1 %] |
72 |
[% SET number_of_private_shelves = 0 %] |
| 68 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=0" tabindex="-1" role="menuitem"><strong>Your lists</strong></a> |
73 |
[% FOREACH s IN some_private_shelves %] |
| 69 |
[% IF loggedinusername %] |
74 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=view&shelfnumber=[% s.shelfnumber | uri %]&sortfield=[% s.sortfield | uri %]" tabindex="-1" role="menuitem">[% s.shelfname | html %]</a> |
| 70 |
[% IF some_private_shelves.count %] |
75 |
[% SET number_of_private_shelves = number_of_private_shelves + 1 %] |
| 71 |
[% SET number_of_private_shelves = 0 %] |
76 |
[% IF number_of_private_shelves >= 10 %][% LAST %][% END %] |
| 72 |
[% FOREACH s IN some_private_shelves %] |
77 |
[% END %] |
| 73 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=view&shelfnumber=[% s.shelfnumber | uri %]&sortfield=[% s.sortfield | uri %]" tabindex="-1" role="menuitem">[% s.shelfname | html %]</a> |
78 |
[% IF some_private_shelves > 10 %] |
| 74 |
[% SET number_of_private_shelves = number_of_private_shelves + 1 %] |
79 |
<a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=0" tabindex="-1" role="menuitem">View all</a> |
| 75 |
[% IF number_of_private_shelves >= 10 %][% LAST %][% END %] |
80 |
[% END %] |
| 76 |
[% END %] |
81 |
[% ELSE %] |
| 77 |
[% IF some_private_shelves > 10 %] |
82 |
<a class="dropdown-item disabled" aria-disabled="true" href="#" tabindex="-1" role="menuitem">No private lists</a> |
| 78 |
<a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=list&public=0" tabindex="-1" role="menuitem">View all</a> |
|
|
| 79 |
[% END %] |
83 |
[% END %] |
|
|
84 |
<a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=add_form" tabindex="-1" role="menuitem">New list</a> |
| 80 |
[% ELSE %] |
85 |
[% ELSE %] |
| 81 |
<a class="dropdown-item disabled" aria-disabled="true" href="#" tabindex="-1" role="menuitem">No private lists</a> |
86 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=add_form" tabindex="-1" role="menuitem">Log in to create your own lists</a> |
| 82 |
[% END %] |
87 |
[% END # / IF loggedinusername %] |
| 83 |
<a class="dropdown-item listmenulink" href="/cgi-bin/koha/opac-shelves.pl?op=add_form" tabindex="-1" role="menuitem">New list</a> |
88 |
[% END # / IF opacuserlogin %] |
| 84 |
[% ELSE %] |
89 |
</div> <!-- / .dropdown-menu --> |
| 85 |
<a class="dropdown-item" href="/cgi-bin/koha/opac-shelves.pl?op=add_form" tabindex="-1" role="menuitem">Log in to create your own lists</a> |
90 |
</li> <!-- / .nav-item.dropdown --> |
| 86 |
[% END # / IF loggedinusername %] |
91 |
[% END # / IF opacuserlogin || some_public_shelves < 1 %] |
| 87 |
[% END # / IF opacuserlogin %] |
|
|
| 88 |
</div> <!-- / .dropdown-menu --> |
| 89 |
</li> <!-- / .nav-item.dropdown --> |
| 90 |
[% END # / IF virtualshelves %] |
92 |
[% END # / IF virtualshelves %] |
| 91 |
[% IF Koha.Preference( 'OpacTrustedCheckout' ) %] |
93 |
[% IF Koha.Preference( 'OpacTrustedCheckout' ) %] |
| 92 |
<li class="nav-item"> |
94 |
<li class="nav-item"> |
| 93 |
- |
|
|