View | Details | Raw Unified | Return to bug 14955
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/facets.inc (-10 / +9 lines)
Lines 21-39 Link Here
21
[% IF ( facets_loo.type_label_HoldingLibrary ) %]<span id="facet-holding-libraries">Holding libraries</span>[% END %]
21
[% IF ( facets_loo.type_label_HoldingLibrary ) %]<span id="facet-holding-libraries">Holding libraries</span>[% END %]
22
[% IF facets_loo.type_label_Location %]<span id="facet-locations">Locations</span>[% END %]
22
[% IF facets_loo.type_label_Location %]<span id="facet-locations">Locations</span>[% END %]
23
<ul>
23
<ul>
24
  [% SET url = "/cgi-bin/koha/catalogue/search.pl?" _ query_cgi _ limit_cgi %]
25
  [% IF ( sort_by ) %]
26
    [% url = BLOCK %][% url %][% "&amp;sort_by=" _ sort_by |url %][% END %]
27
  [% END %]
24
  [% FOREACH facet IN facets_loo.facets %]
28
  [% FOREACH facet IN facets_loo.facets %]
25
    <li>
29
    <li>
26
      [% SET url = "/cgi-bin/koha/catalogue/search.pl?" _ query_cgi _ limit_cgi %]
27
      [% IF ( sort_by ) %]
28
        [% url = BLOCK %][% url %][% "&amp;sort_by=" _ sort_by |url %][% END %]
29
      [% END %]
30
      [% IF facet.active %]
30
      [% IF facet.active %]
31
        [% SET url = url _ "&amp;nolimit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
31
        [% SET local_url = url _ "&amp;nolimit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
32
        <span class="facet-label">[% facet.facet_label_value %]</span>
32
        <span class="facet-label">[% facet.facet_label_value %]</span>
33
        [<a href="[% url %]" title="Remove facet [% facet.facet_link_value | html %]">x</a>]
33
        [<a href="[% local_url %]" title="Remove facet [% facet.facet_link_value | html %]">x</a>]
34
      [% ELSE %]
34
      [% ELSE %]
35
        [% SET url = url _ "&amp;limit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
35
        [% SET local_url = url _ "&amp;limit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
36
        <span class="facet-label"><a href="[% url %]" title="[% facet.facet_title_value |html %]">[% facet.facet_label_value %]</a></span>
36
        <span class="facet-label"><a href="[% local_url %]" title="[% facet.facet_title_value |html %]">[% facet.facet_label_value %]</a></span>
37
        [% IF ( displayFacetCount ) %]
37
        [% IF ( displayFacetCount ) %]
38
          <span class="facet-count"> ([% facet.facet_count %])</span>
38
          <span class="facet-count"> ([% facet.facet_count %])</span>
39
        [% END %]
39
        [% END %]
Lines 42-49 Link Here
42
  [% END %]
42
  [% END %]
43
  [% IF ( facets_loo.expandable ) %]
43
  [% IF ( facets_loo.expandable ) %]
44
      <li class="showmore">
44
      <li class="showmore">
45
          <a href="/cgi-bin/koha/catalogue/search.pl?[% query_cgi %][% limit_cgi |url %][% IF ( sort_by ) %]&amp;sort_by=[% sort_by |url %][% END %][% IF ( offset ) %]
45
          <a href="[% url %][% IF offset %]&amp;offset=[% offset |url %][% END %]&amp;expand=[% facets_loo.expand |url %]#[% facets_loo.type_id |url %]">Show more</a>
46
                  &amp;offset=[% offset |url %][% END %]&amp;expand=[% facets_loo.expand |url %]#[% facets_loo.type_id |url %]">Show more</a>
47
      </li>
46
      </li>
48
  [% END %]
47
  [% END %]
49
</ul></li>
48
</ul></li>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-facets.inc (-10 / +8 lines)
Lines 30-48 Link Here
30
                        [% END %]
30
                        [% END %]
31
                        [% IF facets_loo.type_label_Location %]<h5 id="facet-locations">Locations</h5>[% END %]
31
                        [% IF facets_loo.type_label_Location %]<h5 id="facet-locations">Locations</h5>[% END %]
32
                        <ul>
32
                        <ul>
33
                            [% SET url = "/cgi-bin/koha/opac-search.pl?" _ query_cgi _ limit_cgi %]
34
                            [% IF ( sort_by ) %]
35
                              [% url = BLOCK %][% url %][% "&amp;sort_by=" _ sort_by |url %][% END %]
36
                            [% END %]
33
                            [% FOREACH facet IN facets_loo.facets %]
37
                            [% FOREACH facet IN facets_loo.facets %]
34
                                <li>
38
                                <li>
35
                                  [% SET url = "/cgi-bin/koha/opac-search.pl?" _ query_cgi _ limit_cgi %]
36
                                  [% IF ( sort_by ) %]
37
                                    [% url = BLOCK %][% url %][% "&amp;sort_by=" _ sort_by |url %][% END %]
38
                                  [% END %]
39
                                  [% IF facet.active %]
39
                                  [% IF facet.active %]
40
                                    [% SET url = url _ "&amp;nolimit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
40
                                    [% SET local_url = url _ "&amp;nolimit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
41
                                    <span class="facet-label">[% facet.facet_label_value %]</span>
41
                                    <span class="facet-label">[% facet.facet_label_value %]</span>
42
                                    [<a href="[% url %]" title="Remove facet [% facet.facet_link_value | html %]">x</a>]
42
                                    [<a href="[% url %]" title="Remove facet [% facet.facet_link_value | html %]">x</a>]
43
                                  [% ELSE %]
43
                                  [% ELSE %]
44
                                    [% SET url = url _ "&amp;limit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
44
                                    [% SET local_url = url _ "&amp;limit=" _ facet.type_link_value _ ":" _ facet.facet_link_value %]
45
                                    <span class="facet-label"><a href="[% url %]" title="[% facet.facet_title_value |html %]">[% facet.facet_label_value %]</a></span>
45
                                    <span class="facet-label"><a href="[% local_url %]" title="[% facet.facet_title_value |html %]">[% facet.facet_label_value %]</a></span>
46
                                    [% IF ( displayFacetCount ) %]
46
                                    [% IF ( displayFacetCount ) %]
47
                                      <span class="facet-count"> ([% facet.facet_count %])</span>
47
                                      <span class="facet-count"> ([% facet.facet_count %])</span>
48
                                    [% END %]
48
                                    [% END %]
Lines 51-58 Link Here
51
                            [% END %]
51
                            [% END %]
52
                            [% IF ( facets_loo.expandable ) %]
52
                            [% IF ( facets_loo.expandable ) %]
53
                                <li class="showmore">
53
                                <li class="showmore">
54
                                    <a href="/cgi-bin/koha/opac-search.pl?[% query_cgi %][% limit_cgi |url %][% IF ( sort_by ) %]&amp;sort_by=[% sort_by |url %][% END %][% IF ( offset ) %]
54
                                    <a href="[% url %][% IF offset %]&amp;offset=[% offset |url %][% END %]&amp;expand=[% facets_loo.expand |url %]#[% facets_loo.type_id |url %]">Show more</a>
55
                                            &amp;offset=[% offset |url %][% END %]&amp;expand=[% facets_loo.expand |url %]#[% facets_loo.type_id |url %]">Show more</a>
56
                                </li>
55
                                </li>
57
                            [% END %]
56
                            [% END %]
58
                        </ul>
57
                        </ul>
59
- 

Return to bug 14955