From 092ecc19e8264d8623269c88eb702866f1abe2b7 Mon Sep 17 00:00:00 2001 From: Hammat Wele Date: Wed, 28 Feb 2024 17:23:04 +0000 Subject: [PATCH] Bug 31736: Context for translation: 'All' (All libraries) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch adds context for translators for the term 'All' when it refers to 'All libraries'. This patch replace the term 'All' when it refers to 'All libraries' by 'All libraries/branches' to be able to translate by gender 1. Apply patch 2. View the following pages --> The pages work (no errors) --> No spelling errors in 'All' libraries - Acquisitions > Invoices (Library filter on the left) - Circulation > Holds queue (Library filter) - Reports > Cash register (Transaction library filter) - Reports > Items lost (Library filter) - Serials > Check expiration (Library filter) - Serials > Search settings icon in the search bar > Advanced search (Library filter) - Acquisitions > Add to basket > From a subscription (Library filter on the left) - Installer > Onboarding > New circulation rule (Library) 3. Update the po files gulp po:update --lang xx-XX for example, gulp po:update --lang fr-CA 4. Add tranlation for for 'All libraries/branches' in the file xx-XX-staff-prog.po (need after to be added in koha-l10n) For example, I translated 'All libraries/branches' by 'Toutes les bibliothèques' #: koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoices.tt:383 #: koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt:254 #: koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt:64 #: koha-tmpl/intranet-tmpl/prog/en/modules/reports/cash_register_stats.tt:115 #: koha-tmpl/intranet-tmpl/prog/en/modules/reports/itemslost.tt:146 #: koha-tmpl/intranet-tmpl/prog/en/modules/serials/checkexpiration.tt:48 #: koha-tmpl/intranet-tmpl/prog/en/includes/serials-advsearch.inc:41 #: koha-tmpl/intranet-tmpl/prog/en/includes/subscriptions-search.inc:34 #, c-format msgid "All libraries/branches" msgstr "Toutes les bibliothèques" 5. Install a new language 6.1. Run the following commands in the terminal, replacing xx-XX with the language code (e.g. fr-CA) ./misc/translator/translate install xx-XX 6.2. In the Koha staff interface, go to Administration > System preferences 6.3. Search for language 6.4. Check the box next to the new language 6.5. Save 7. Switch the language of the interface 8. Redo step 2 --> The pages still work (no errors) --> The 'All libraries/branches' libraries string should be replaced by whatever you put in step 4 --- koha-tmpl/intranet-tmpl/prog/en/includes/serials-advsearch.inc | 2 +- .../intranet-tmpl/prog/en/includes/subscriptions-search.inc | 2 +- koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoices.tt | 2 +- koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt | 2 +- .../intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt | 2 +- .../prog/en/modules/reports/cash_register_stats.tt | 2 +- koha-tmpl/intranet-tmpl/prog/en/modules/reports/itemslost.tt | 2 +- .../intranet-tmpl/prog/en/modules/serials/checkexpiration.tt | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/serials-advsearch.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/serials-advsearch.inc index ec34b6f073..63f316945a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/serials-advsearch.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/serials-advsearch.inc @@ -37,7 +37,7 @@
  • diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/subscriptions-search.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/subscriptions-search.inc index 5e1275d249..fb68cc4456 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/subscriptions-search.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/subscriptions-search.inc @@ -30,7 +30,7 @@
  • diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoices.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoices.tt index 16108eb8eb..554ccb1df0 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoices.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoices.tt @@ -384,7 +384,7 @@
  • diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt index 24978b60d5..6e8c3e7f26 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt @@ -254,7 +254,7 @@ diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt index 4105d079db..3afcbc8f1f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/onboarding/onboardingstep5.tt @@ -64,7 +64,7 @@ - + [% FOREACH branchloo IN branchloop %] [% IF ( branchloo.selected ) %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/itemslost.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/itemslost.tt index c2b4cf36e6..6f1075d4b5 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/itemslost.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/itemslost.tt @@ -148,7 +148,7 @@
  • - + [% PROCESS options_for_libraries libraries => Branches.all( selected => branch ) %]
  • -- 2.34.1