@@ -, +, @@ there are existent subscriptions an error message stating to delete all subscriptions before deleting record. --- koha-tmpl/intranet-tmpl/prog/en/includes/catalog-strings.inc | 1 + koha-tmpl/intranet-tmpl/prog/js/catalog.js | 2 ++ 2 files changed, 3 insertions(+) --- a/koha-tmpl/intranet-tmpl/prog/en/includes/catalog-strings.inc +++ a/koha-tmpl/intranet-tmpl/prog/en/includes/catalog-strings.inc @@ -10,6 +10,7 @@ [% SET cancelled = Context.Scalar(orders, "filter_by_cancelled") %] var countorders = [% current.count || 0 | html %]; var countdeletedorders = [% cancelled.count || 0 | html %]; + var subscriptionscount = [% biblio.subscriptions.count || 0 | html %]; var searchid = '[% searchid | html %]'; /* provide Z3950 search points */ --- a/koha-tmpl/intranet-tmpl/prog/js/catalog.js +++ a/koha-tmpl/intranet-tmpl/prog/js/catalog.js @@ -44,6 +44,8 @@ function confirm_deletion(link) { } } else if ( holdcount > 0 ) { is_confirmed = confirm( __("%s holds(s) for this record. Are you sure you want to delete this record?").format(holdcount)); + } else if (subscriptionscount > 0){ + is_confirmed = alert(__("%s subscription(s) are attached to this record. You must delete all subscription before deleting this record.").format(subscriptionscount)); } else { is_confirmed = confirm( __("Are you sure you want to delete this record?") ); } --