Bug 20797: Add link to biblio detail view from ILL detail view
authorAndrew Isherwood <andrew.isherwood@ptfs-europe.com>
Wed, 23 May 2018 11:26:25 +0000 (12:26 +0100)
committerTomas Cohen Arazi <tomascohen@theke.io>
Sat, 13 Oct 2018 11:54:57 +0000 (08:54 -0300)
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt

index 6a17b7d..fb58033 100644 (file)
                 '</a>';
         };
 
+        // Our 'render' function for biblio_id
+        var createBiblioLink = function(data, type, row) {
+            return '<a title="' + _("View biblio details") + '" ' +
+                'href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=' +
+                row.biblio_id + '">' +
+                row.biblio_id +
+                '</a>';
+        };
+
         // Our 'render' function for the library name
         var createLibrary = function(data, type, row) {
             return row.library.branchname;
             },
             biblio_id: {
                 name: _("Bibliograpic Record ID")
+                func: createBiblioLink
             },
             library: {
                 name: _("Library"),
 
                                 <div class="biblio_id">
                                     <span class="label biblio_id">Bibliographic record ID:</span>
-                                    [% IF request.biblio_id %][% request.biblio_id | html %][% ELSE %]<span>N/A</span>[% END %]
+                                    [% IF request.biblio_id %]
+                                        <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% request.biblio_id | html %]">[% request.biblio_id | html %]</a>
+                                    [% ELSE %]
+                                        <span>N/A</span>
+                                    [% END %]
                                 </div>
                                 <div class="branchcode">
                                     <span class="label branchcode">Library:</span>