Bug 29609: Centralized code to build the link to a biblio detail page
[srvgit] / koha-tmpl / opac-tmpl / bootstrap / en / includes / html_helpers.inc
index 7a964de..d849154 100644 (file)
         </div>
     [% END %]
 [% END %]
+
+[% BLOCK biblio_a_href -%]
+    [%- IF Koha.Preference('BiblioDefaultView') == 'marc' -%]
+        [%- SET this_biblio_href = "/cgi-bin/koha/opac-MARCdetail.pl?biblionumber=" -%]
+    [%- ELSIF Koha.Preference('BiblioDefaultView') == 'isbd' -%]
+        [%- SET this_biblio_href = "/cgi-bin/koha/opac-ISBDdetail.pl?biblionumber=" -%]
+    [%- ELSE -%]
+        [%- SET this_biblio_href = "/cgi-bin/koha/opac-detail.pl?biblionumber=" -%]
+    [%- END -%]
+    [%- this_biblio_href | url %][% biblionumber | url -%]
+[%- END %]