Bugzilla – Attachment 173371 Details for
Bug 38085
Untranslatable options in OPACAuthorIdentifiersAndInformation
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 38085: Pick multiple_sortable options for translation
Bug-38085-Pick-multiplesortable-options-for-transl.patch (text/plain), 2.47 KB, created by
Tomás Cohen Arazi (tcohen)
on 2024-10-25 14:25:08 UTC
(
hide
)
Description:
Bug 38085: Pick multiple_sortable options for translation
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2024-10-25 14:25:08 UTC
Size:
2.47 KB
patch
obsolete
>From 4c34389af8c212d4ce8b194410684a9ac60fec99 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 7 Oct 2024 11:31:36 +0200 >Subject: [PATCH] Bug 38085: Pick multiple_sortable options for translation > >Bug 29948 added a "multiple_sortable" type for sysprefs, to have the >options sortable. But the options were not picked for translation. > >This patch fixes it. > >Test plan: >Run `cd misc/translator && perl translate update LANG` before and after >this patch. Notice that with this patch you see the different options of >OPACAuthorIdentifiersAndInformation in the LANG-pref.po file (eg. >"Associated group (373$a$s$t$u$v$0)") >Translate the options >Install the translated version of the templates and confirm that the >strings appear translated on the interface. > >Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >--- > misc/translator/LangInstaller.pm | 2 +- > misc/translator/xgettext-pref | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > >diff --git a/misc/translator/LangInstaller.pm b/misc/translator/LangInstaller.pm >index a0f323121eb..15bee8355a5 100644 >--- a/misc/translator/LangInstaller.pm >+++ b/misc/translator/LangInstaller.pm >@@ -225,7 +225,7 @@ sub get_translated_pref { > my $value = $syspref->{$key}; > > my $translated_value = $value; >- if (($key eq 'choices' || $key eq 'multiple') && ref($value) eq 'HASH') { >+ if (($key eq 'choices' || $key eq 'multiple' || $key eq 'multiple_sortable') && ref($value) eq 'HASH') { > $translated_value = { > map { > my $msgid = sprintf('%s#%s# %s', $file, $pref_name, $value->{$_}); >diff --git a/misc/translator/xgettext-pref b/misc/translator/xgettext-pref >index 0068ae68690..77b11610ec7 100755 >--- a/misc/translator/xgettext-pref >+++ b/misc/translator/xgettext-pref >@@ -120,7 +120,7 @@ sub add_prefs { > for my $element (@$pref) { > if ( ref($element) eq 'HASH' ) { > while ( my ( $key, $value ) = each(%$element) ) { >- next unless $key eq 'choices' or $key eq 'multiple'; >+ next unless $key eq 'choices' or $key eq 'multiple' or $key eq 'multiple_sortable'; > next unless ref($value) eq 'HASH'; > for my $ckey ( keys %$value ) { > my $msgid = sprintf('%s#%s# %s', basename($file), $pref_name, $value->{$ckey}); >-- >2.47.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 38085
:
172448
|
172472
| 173371