3.0.x fix for Bug 5082, Default framework name not translatable
This commit is contained in:
parent
9ad9e65d3f
commit
f4bf61ce1b
|
|
@ -89,30 +89,22 @@ my $itemcount = GetItemsCount($biblionumber);
|
|||
$template->param( count => $itemcount,
|
||||
bibliotitle => $biblio->{title}, );
|
||||
|
||||
#Getting the list of all frameworks
|
||||
my $queryfwk =
|
||||
$dbh->prepare("select frameworktext, frameworkcode from biblio_framework");
|
||||
$queryfwk->execute;
|
||||
my %select_fwk;
|
||||
my @select_fwk;
|
||||
my $curfwk;
|
||||
push @select_fwk, "Default";
|
||||
$select_fwk{"Default"} = "Default";
|
||||
|
||||
while ( my ( $description, $fwk ) = $queryfwk->fetchrow ) {
|
||||
push @select_fwk, $fwk;
|
||||
$select_fwk{$fwk} = $description;
|
||||
}
|
||||
$curfwk=$frameworkcode;
|
||||
my $framework=CGI::scrolling_list( -name => 'Frameworks',
|
||||
-id => 'Frameworks',
|
||||
-default => $curfwk,
|
||||
-OnChange => 'Changefwk(this);',
|
||||
-values => \@select_fwk,
|
||||
-labels => \%select_fwk,
|
||||
-size => 1,
|
||||
-multiple => 0 );
|
||||
$template->param(framework => $framework);
|
||||
# Getting the list of all frameworks
|
||||
# get framework list
|
||||
my $frameworks = getframeworks;
|
||||
my @frameworkcodeloop;
|
||||
foreach my $thisframeworkcode ( keys %$frameworks ) {
|
||||
warn $thisframeworkcode;
|
||||
my %row = (
|
||||
value => $thisframeworkcode,
|
||||
frameworktext => $frameworks->{$thisframeworkcode}->{'frameworktext'},
|
||||
);
|
||||
if ($frameworkcode eq $thisframeworkcode){
|
||||
$row{'selected'}="selected=\"selected\"";
|
||||
}
|
||||
push @frameworkcodeloop, \%row;
|
||||
}
|
||||
$template->param( frameworkcodeloop => \@frameworkcodeloop );
|
||||
# fill arrays
|
||||
my @loop_data = ();
|
||||
my $tag;
|
||||
|
|
|
|||
|
|
@ -36,7 +36,12 @@ function Changefwk(FwkList) {
|
|||
|
||||
<!-- /TMPL_UNLESS -->
|
||||
|
||||
<p><b>With Framework :<!--TMPL_VAR Name="framework" --></b></p>
|
||||
<p><b>With Framework : <select name="Frameworks" id="Frameworks" onchange="Changefwk(this);">
|
||||
<option value="">Default</option>
|
||||
<!-- TMPL_LOOP NAME="frameworkcodeloop" -->
|
||||
<!-- TMPL_IF NAME="selected" --><option value="<!-- TMPL_VAR NAME="value"-->" selected="selected"><!-- TMPL_VAR NAME="frameworktext" --></option><!-- TMPL_ELSE --><option value="<!-- TMPL_VAR NAME="value"-->"><!-- TMPL_VAR NAME="frameworktext" --></option><!-- /TMPL_IF -->
|
||||
<!-- /TMPL_LOOP -->
|
||||
</select></b></p>
|
||||
|
||||
<div id="bibliotabs" class="toptabs numbered">
|
||||
<ul>
|
||||
|
|
|
|||
Loading…
Reference in New Issue