From 3ec7a3fbfba20205d1f2ada4184f4b9f49ae7cb3 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 18 Apr 2023 15:36:52 +0200 Subject: [PATCH] Bug 33568: Restore action buttons MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Owen Leonard Signed-off-by: Laurence Rault Signed-off-by: Emily Lamancusa Signed-off-by: Tomás Cohen Arazi Signed-off-by: Katrin Fischer --- .../prog/en/modules/catalogue/detail.tt | 21 +++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt index d5a9fe3010..b0d29e87c0 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt @@ -2931,8 +2931,25 @@ [% IF CAN_user_editcatalogue_edit_items %] { data: function( row, type, val, meta ) { - let result = 'Edit + Delete'; // FIXME Add links - return result; + let nodes = ''; + if ( can_edit_items_from[row.holding_library_id] ){ + [% IF Koha.Preference('LocalCoverImages') OR Koha.Preference('OPACLocalCoverImages') %] + nodes += '
'; + nodes += ' Edit'.format(row.biblio_id, row.item_id); + nodes += ' '; + nodes += '
'; + [% ELSE %] + nodes += ' Edit'.format(row.biblio_id, row.item_id); + [% END %] + } + [% IF bundlesEnabled %] + // FIXME How do we handle that correctly? + //nodes += ''.format(row.bundled, row.bundled_lost); + [% END %] + + return nodes; }, className: "actions", searchable: false, -- 2.39.5