--- loncom/interface/lonparmset.pm 2008/06/27 00:02:55 1.402
+++ loncom/interface/lonparmset.pm 2008/10/10 15:29:17 1.412
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Handler to set parameters for assessments
#
-# $Id: lonparmset.pm,v 1.402 2008/06/27 00:02:55 raeburn Exp $
+# $Id: lonparmset.pm,v 1.412 2008/10/10 15:29:17 bisitz Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -973,7 +973,7 @@ sub extractResourceInformation {
if (!exists($$allparms{$name}) || $$allparms{$name} =~ m/^\s*$/ ) {
my $display= &Apache::lonnet::metadata($srcf,$key.'.display');
my $parmdis = $display;
- $parmdis =~ s/\[Part.*$//g;
+ $parmdis =~ s/\s*\[Part.*$//g;
$$allparms{$name}=$parmdis;
if (ref($defkeytype)) {
$$defkeytype{$name}=
@@ -985,7 +985,7 @@ sub extractResourceInformation {
# allparts is a hash of all parts
#
my $part= &Apache::lonnet::metadata($srcf,$key.'.part');
- $$allparts{$part} = "Part: $part";
+ $$allparts{$part} = &mt('Part: [_1]',$part);
#
# Remember all keys going with this resource
#
@@ -1107,8 +1107,8 @@ ENDSCRIPT
if ($$pscat[0] eq "all" || grep $_ eq $tempkey, @{$pscat}) {
$r->print(' checked');
}
- $r->print('>'.($$allparms{$tempkey}=~/\S/ ? $$allparms{$tempkey}
- : $tempkey)
+ $r->print('>'.($$allparms{$tempkey}=~/\S/ ? &mt($$allparms{$tempkey})
+ : &mt($tempkey))
.'');
$cnt++;
if ($cnt==3) {
@@ -1116,21 +1116,46 @@ ENDSCRIPT
$cnt=0;
}
}
- $r->print('
-
');
+ $r->print(''
+ .''
+ );
}
sub partmenu {
@@ -1160,21 +1185,18 @@ sub usermenu {
my $chooseopt=&Apache::loncommon::select_dom_form($udom,'udom').' '.
&Apache::loncommon::selectstudent_link('parmform','uname','udom');
my $selscript=&Apache::loncommon::studentbrowser_javascript();
- my %lt=&Apache::lonlocal::texthash(
- 'se' => "Section",
- 'gr' => "Group",
- 'fu' => "For User",
- 'oi' => "or ID",
- 'ad' => "at Domain"
- );
+
my $sections='';
my %sectionhash = &Apache::loncommon::get_sections();
my $groups;
my %grouphash = &Apache::longroup::coursegroups();
+ my $g_s_header='';
+ my $g_s_footer='';
+
if (%sectionhash) {
- $sections=$lt{'se'}.':