From 75bfe811a08b5599df2f5a5f54d94382868a4895 Mon Sep 17 00:00:00 2001 From: Caroline Cyr La Rose Date: Wed, 5 Feb 2025 14:57:37 -0500 Subject: [PATCH] Bug 39045: Add translation context to vendor status (active/inactive) This patch adds translation context to 'Active' and 'Inactive' when used for the vendor status in acquisitions. To test: 1. Go to Acquisitions 2. Click 'New vendor' --> At the bottom of the form, in the 'Ordering information' section, there should be a choice Vendor is: Active Inactive 3. Enter a vendor name 4. Click 'Save' 5. Click the name of the vendor --> In the 'Ordering information' box (bottom left), there should be a mention Vendor is: Active 6. Click 'Edit vendor' 7. Choose 'Inactive' 8. Click 'Save' --> Next to the vendor name, it should say '(inactive)' 9. Click the name of the vendor --> In the 'Ordering information' box (bottom left), there should be a mention Vendor is: Inactive 10. Apply patch 11. Update translations ktd --shell gulp po:update --lang fr-CA 12. View the fr-CA-messages.po file --> There should be entries with 'Vendor status' in msgctxt 13. Optionally, translate the strings (remember to remove the fuzzy flag, if any) 14. Install new translations ktd --root --shell koha-translate --install fr-CA --dev kohadev koha-translate --update fr-CA --dev kohadev 15. Enable the new language in Administration > System preferences > StaffInterfaceLanguages 16. Repeat steps 1-9 --> Translations should be whatever you put in the po file --- .../intranet-tmpl/prog/en/modules/acqui/booksellers.tt | 2 +- .../intranet-tmpl/prog/en/modules/acqui/supplier.tt | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/booksellers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/booksellers.tt index e567b85c1b..d6948deae1 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/booksellers.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/booksellers.tt @@ -89,7 +89,7 @@ [% END %] [% IF (supplier.vendor_type) %]([% AuthorisedValues.GetByCode( 'VENDOR_TYPE', supplier.vendor_type ) | html %])[% END %] - [% IF ( !supplier.active ) %](inactive)[% END %] + [% IF ( !supplier.active ) %][% tp('Vendor status', '(inactive)') | html %][% END %] [% IF ( count > 1 ) %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tt index 03b0924148..5bd0a5aea9 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tt @@ -274,14 +274,14 @@
  1. [% IF ( active ) %] - + - + [% ELSE %] - + - + [% END %]