Lines 1-56
Link Here
|
1 |
[% IF facets_loop %] |
|
|
2 |
<div id="search-facets"> |
3 |
<h4>Refine your search</h4> |
4 |
<ul> |
5 |
[% FOR facets IN facets_loop %] |
6 |
<li> |
7 |
[% facets.label %] |
8 |
<ul class="facets_list"> |
9 |
[% FOR value IN facets.values %] |
10 |
<li> |
11 |
[% IF ( value.active ) %] |
12 |
[% value.lib %] ([% value.count %]) |
13 |
[% SET url = "/cgi-bin/koha/opac-search.pl?" %] |
14 |
[% SET first = 1 %] |
15 |
[% FOR p IN follower_params %] |
16 |
[% IF p.var != 'filters' %] |
17 |
[% UNLESS first %] |
18 |
[% SET url = url _ '&' %] |
19 |
[% END %] |
20 |
[% SET first = 0 %] |
21 |
[% SET url = url _ p.var _ '=' _ p.val %] |
22 |
[% END %] |
23 |
[% END %] |
24 |
[% FOR f IN filters %] |
25 |
[% UNLESS f.var == facets.indexname && f.val == value.value %] |
26 |
[% SET url = url _ '&filters=' _ f.var _ ':"' _ f.val _ '"' %] |
27 |
[% END %] |
28 |
[% END %] |
29 |
[<a href="[% url |url %]">x</a>] |
30 |
[% ELSE %] |
31 |
[% SET url = "/cgi-bin/koha/opac-search.pl?" %] |
32 |
[% SET first = 1 %] |
33 |
[% FOR p IN follower_params %] |
34 |
[% IF p.var != 'filters' %] |
35 |
[% UNLESS first %] |
36 |
[% SET url = url _ '&' %] |
37 |
[% END %] |
38 |
[% SET first = 0 %] |
39 |
[% SET url = url _ p.var _ '=' _ p.val %] |
40 |
[% END %] |
41 |
[% END %] |
42 |
[% FOR f IN filters %] |
43 |
[% SET url = url _ '&filters=' _ f.var _ ':"' _ f.val _ '"' %] |
44 |
[% END %] |
45 |
[% SET url = url _ '&filters=' _ facets.indexname _ ':"' _ value.value _ '"' %] |
46 |
|
47 |
<a href="[% url |url %]">[% value.lib %]</a> ([% value.count %]) |
48 |
[% END %] |
49 |
</li> |
50 |
[% END %] |
51 |
</ul> |
52 |
</li> |
53 |
[% END %] |
54 |
</ul> |
55 |
</div> |
56 |
[% END %] |