Browse Source

Bug 11263: Use all languages instead of just the translated ones

This patch produces the same dropdown list as the one in the adv search.
With this way, it won't be necessary to install additional templates to
fill the locale list.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
3.16.x
Jonathan Druart 11 years ago
committed by Galen Charlton
parent
commit
507944e41b
  1. 6
      serials/subscription-add.pl
  2. 7
      serials/subscription-numberpatterns.pl

6
serials/subscription-add.pl

@ -215,10 +215,10 @@ if ($op eq 'addsubscription') {
my $languages = [ map {
{
language => $_->{language},
description => $_->{native_description} || $_->{language}
language => $_->{iso639_2_code},
description => $_->{language_description} || $_->{language}
}
} @{ C4::Languages::getTranslatedLanguages() } ];
} @{ C4::Languages::getAllLanguages() } ];
$template->param( locales => $languages );

7
serials/subscription-numberpatterns.pl

@ -105,12 +105,13 @@ if($op && ($op eq 'new' || $op eq 'modify')) {
my @frequencies = GetSubscriptionFrequencies();
my @subtypes;
push @subtypes, { value => $_ } for (qw/ issues weeks months /);
my $languages = [ map {
{
language => $_->{language},
description => $_->{native_description} || $_->{language}
language => $_->{iso639_2_code},
description => $_->{language_description} || $_->{language}
}
} @{ C4::Languages::getTranslatedLanguages() } ];
} @{ C4::Languages::getAllLanguages() } ];
$template->param(
$op => 1,

Loading…
Cancel
Save