From f777f5930d9608ea143afa1dd8abb3820100fd9a Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Thu, 12 Dec 2024 08:25:41 -0300 Subject: [PATCH] Bug 38684: Improve translatability in cat-toolbar.inc This patch converts strings using * *subscription(s)* * *item(s)* into different strings for the singular and plural forms. This helps translating and is also more accurate for the end user. To test: 1. Have a record with 2 items and 2 subscriptions 2. hover on the _Edit > Delete record_ dropdown item => FAIL: Mixed form string about items 3. Delete one item at a time, repeating 2 => FAIL: Mixed form string at each step 4. Once items are deleted, repeat 2 => FAIL: Mixed form string about subscriptions 5. Delete one subscription at a time, repeating 2 => FAIL: Mixed form string at each step 6. Apply this patch 7. Repeat 1-5 => SUCCESS: Different message in singular and plural forms => SUCCESS: The message is correct 8. Sign off :-D Signed-off-by: Tomas Cohen Arazi Signed-off-by: Owen Leonard --- koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) 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 36d924b952..41332a2b8d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc @@ -130,11 +130,12 @@ [% IF CAN_user_editcatalogue_edit_catalogue or ( frameworkcode == 'FA' and CAN_user_editcatalogue_fast_cataloging ) %] [% IF ( count ) %] -
  • +
  • count }) -%]. You must delete all items before deleting this record"> Delete record
  • [% ELSIF ( biblio.subscriptions.count ) %] -
  • + [%- SET subscriptions_count = biblio.subscriptions.count -%] +
  • subscriptions_count }) -%]. You must delete all subscriptions before deleting this record"> Delete record
  • [% ELSE %] -- 2.39.5