From 87864a5ccf03ae2c7499fb22c1884e6bedcd9aaf Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 10 May 2023 11:21:19 +0200 Subject: [PATCH] Bug 33578: Fix patron restriction types edition When editing an existing patron restriction type you'll always get an error on saving: Label is already in use To test: * Activate use of patron restriction types * Edit any of the system types * Create new ones Signed-off-by: Michaela Sieber Signed-off-by: Marcel de Rooy Signed-off-by: Tomas Cohen Arazi (cherry picked from commit 9e32945f208fa16c773dfc0867754649fcf820ca) Signed-off-by: Martin Renvoize --- koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt | 1 + 1 file changed, 1 insertion(+) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt index 5b9dcc7ca4..b8f0c06b58 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/restrictions.tt @@ -211,6 +211,7 @@ var MSG_DUPLICATE_DISPLAY_TEXT = _("Restriction type label is already in use"); var existing = { [% FOREACH ex IN existing %] + [% NEXT IF ex.code == restriction.code %] [% ex.code | $raw %]: '[% ex.display_text | $raw %]', [% END %] }; -- 2.39.2