From ff03a6895f7e8a959ccc4811287b82634e16ec9a Mon Sep 17 00:00:00 2001 From: Timothy Alexis Vass Date: Fri, 13 Nov 2020 09:47:32 +0000 Subject: [PATCH] Bug 9565: Deleting a biblio should alert/fail if there are existent subscriptions MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Currently Koha will delete a biblio record if there are existent serial subscriptions. This patch will prevent deleting the biblio until attached subscriptions are removed. To test: 1) Add a subscription to a biblio, or check a biblio which has one attached already. 2) Remove all items if there are any. 3) Apply patch. 4) Confirm that the 'Delete record' item is disabled in the list. 5) Sign off. Sponsored by: Lunds Universitetsbibliotek Signed-off-by: Séverine QUEUNE Signed-off-by: Frank Hansen Signed-off-by: Jonathan Druart Signed-off-by: Andrew Fuerste-Henry --- koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc index 85660edcd9..9ee8bde396 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc @@ -68,6 +68,8 @@ [% IF CAN_user_editcatalogue_edit_catalogue or ( frameworkcode == 'FA' and CAN_user_editcatalogue_fast_cataloging ) %] [% IF ( count ) %]
  • Delete record
  • + [% ELSIF ( biblio.subscriptions.count ) %] +
  • Delete record
  • [% ELSE %]
  • Delete record
  • [% END %] -- 2.39.5