--- loncom/interface/lonparmset.pm 2008/08/28 03:54:53 1.407
+++ loncom/interface/lonparmset.pm 2008/10/10 10:19:08 1.410
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Handler to set parameters for assessments
#
-# $Id: lonparmset.pm,v 1.407 2008/08/28 03:54:53 raeburn Exp $
+# $Id: lonparmset.pm,v 1.410 2008/10/10 10:19:08 bisitz Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -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
#
@@ -1116,21 +1116,46 @@ ENDSCRIPT
$cnt=0;
}
}
- $r->print('
-
');
+ $r->print(''
+ .''
+ );
}
sub partmenu {
@@ -2357,6 +2382,8 @@ sub crsenv {
'categories'
=> ''.&mt('Categorize course').' '.
&mt('Display Categories').'',
+ 'datelocale'
+ => ''.&mt('Locale used for course calendar').'',
);
my @Display_Order = ('url','description','courseid','cloners');
(my $can_toggle_cat,$can_categorize) = &can_modify_catsettings($dom);
@@ -2380,6 +2407,7 @@ sub crsenv {
'allow_discussion_post_editing',
'languages',
'timezone',
+ 'datelocale',
'nothideprivileged',
'rndseed',
'receiptalg',
@@ -2433,6 +2461,17 @@ sub crsenv {
&Apache::loncommon::select_timezone($parameter.'_value',
$timezone,
$onchange,$includeempty).'';
+ } elsif ($parameter eq 'datelocale') {
+ my $includeempty = 1;
+ my $locale_obj = &Apache::lonlocal::getdatelocale();
+ my $currdatelocale;
+ if (ref($locale_obj)) {
+ $currdatelocale = $locale_obj->id();
+ }
+ $output .= ''.
+ &Apache::loncommon::select_datelocale($parameter.'_value',
+ $currdatelocale,
+ $onchange,$includeempty).' | ';
} elsif ($parameter eq 'categories') {
my $catdisplay;
if ($values{'categories'} ne '') {
@@ -2570,7 +2609,7 @@ function updateCategories() {
newcategories = newcategories.slice(0,-1);
}
if (unescapedcats.length > 0) {
- usescapedcats = unescapedcats.slice(0,-3);
+ unescapedcats = unescapedcats.slice(0,-3);
}
} else {
if (document.chgcats.usecategory.checked == true) {