--- loncom/interface/londocs.pm 2009/05/21 02:47:48 1.325.2.1
+++ loncom/interface/londocs.pm 2010/01/22 01:23:34 1.325.2.5
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Documents
#
-# $Id: londocs.pm,v 1.325.2.1 2009/05/21 02:47:48 raeburn Exp $
+# $Id: londocs.pm,v 1.325.2.5 2010/01/22 01:23:34 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -145,7 +145,7 @@ sub dumpcourse {
my ($r) = @_;
my $type = &Apache::loncommon::course_type();
$r->print(&Apache::loncommon::start_page('Dump '.$type.' DOCS to Construction Space').
- '
');
+ &mt('Export').'" />');
}
}
@@ -507,7 +551,7 @@ sub create_ims_store {
my $manifestfilename = $$tempexport.$manifest;
if ($ims_manifest = Apache::File->new('>'.$manifestfilename)) {
$$manifestok=1;
- print $ims_manifest
+ print $ims_manifest
''."\n".
' 0) {
my $num = 0;
my $state = '
@@ -1966,7 +2010,7 @@ END
my $ro_set=
((&LONCAPA::map::getparameter($orderidx,'parameter_randomorder'))[0]=~/^yes$/i?' checked="checked"':'');
$rand_order_text ='
-';
+';
}
if ($ispage) {
my $pagename=&escape($pagetitle);
@@ -2010,12 +2054,12 @@ END
$line.=(<
$form_start
-
+
$form_end
$form_start
-
+
$form_end
|
$form_start $rand_order_text $form_end |
@@ -2098,7 +2142,7 @@ sub checkonthis {
if (($errorcount) ||
($warningcount)) {
if ($errorcount) {
- $r->print('
'.
+ $r->print('
'.
&mt('[quant,_1,error]',$errorcount).'');
}
if ($warningcount) {
@@ -2488,14 +2532,19 @@ sub changewarning {
$message='Changes will become active for your current session after [_1], or the next time you log in.';
}
$r->print("\n\n".
-''."\n".
+''."\n".
''."\n\n");
+ &mt('re-initializing '.$course_type).'" onclick="reinit(this.form)" />').
+$help{'Caching'}.''."\n\n");
+
}
@@ -2503,7 +2552,7 @@ sub init_breadcrumbs {
my ($form,$text)=@_;
&Apache::lonhtmlcommon::clear_breadcrumbs();
&Apache::lonhtmlcommon::add_breadcrumb({href=>"/adm/coursedocs",
- text=>"Edit ".&Apache::loncommon::course_type(),
+ text=>&Apache::loncommon::course_type().' Editor',
faq=>273,
bug=>'Instructor Interface',
help => 'Docs_Adding_Course_Doc'});
@@ -2564,7 +2613,7 @@ sub handler {
&init_breadcrumbs('dumpcourse','Dump '.&Apache::loncommon::course_type().' DOCS to Construction Space');
&dumpcourse($r);
} elsif ($allowed && $env{'form.exportcourse'}) {
- &init_breadcrumbs('exportcourse','Export '.&Apache::loncommon::course_type().' to IMS');
+ &init_breadcrumbs('exportcourse','IMS Export');
&exportcourse($r);
} else {
# is this a standard course?
@@ -2648,7 +2697,11 @@ sub handler {
$script .= &editing_js($udom,$uname);
}
# -------------------------------------------------------------------- Body tag
- $script = '';
+ $script = ''."\n";
my $brcrum = [{href=>"/adm/createuser",text=>"$type Documents"}];
$r->print(&Apache::loncommon::start_page("$type Documents", $script,
{'force_register' => $showdoc,
@@ -2772,13 +2825,24 @@ sub handler {
'grpo' => 'Group Portfolios',
'rost' => 'Course Roster',
'abou' => 'About User',
- 'imsf' => 'Import IMS package',
+ 'imsf' => 'IMS Import',
+ 'imsl' => 'Import IMS package',
'file' => 'File',
'title' => 'Title',
'comment' => 'Comment',
'parse' => 'If HTML file, upload embedded images/multimedia files'
);
# -----------------------------------------------------------------------------
+ my %tabtitles = (
+ main => {
+ Course => &mt('Main Course Documents'),
+ Community => &mt('Main Community Documents'),
+ },
+ supplemental => {
+ Course => &mt('Supplemental Course Documents'),
+ Community => &mt('Supplemental Community Documents'),
+ },
+ );
if ($allowed) {
&update_paste_buffer($coursenum,$coursedom);
my $dumpbut=&dumpbutton();
@@ -2794,8 +2858,7 @@ sub handler {
if (!$folderpath) {
if ($env{'form.folder'} eq '' ||
$env{'form.folder'} eq 'supplemental') {
- $folderpath='default&'.
- &escape(&mt('Main '.$type.' Documents'));
+ $folderpath='default&'.&escape($tabtitles{'main'}{$type});
}
}
unless ($env{'form.pagepath'}) {
@@ -2856,7 +2919,12 @@ ENDCOURSEVERIFY
}
my $postexec='';
if ($folder eq 'default') {
- $r->print('');
+ $r->print(''."\n"
+ );
} else {
#$postexec='self.close();';
}
@@ -2914,27 +2982,27 @@ $uploadtag
ENDFORM
unless ($env{'form.pagepath'}) {
@@ -2944,13 +3012,13 @@ ENDFORM
$uploadtag
- $help{'Adding_External_Resource'}
ENDFORM
}
@@ -2963,7 +3031,7 @@ ENDFORM
$help{'Adding_Folders'}
@@ -2972,7 +3040,7 @@ value="$lt{'newf'}" />$help{'Adding_Fold
$help{'Adding_Pages'}
@@ -2999,7 +3067,7 @@ $uploadtag
$help{'Simple Page'}
+onclick="javascript:makesmppage();" /> $help{'Simple Page'}
@@ -3032,7 +3100,7 @@ $uploadtag
+onclick="javascript:makebulboard();" />
$help{'Bulletin Board'}
@@ -3050,7 +3118,7 @@ $uploadtag
+onclick="javascript:makeabout();" />
@@ -3110,7 +3178,7 @@ ENDBLOCK
if ($folder =~ /^supplemental$/ &&
(($env{'form.folderpath'} =~ /^default\&/) || ($env{'form.folderpath'} eq ''))) {
$env{'form.folderpath'} = 'supplemental&'.
- &escape(&mt('Supplemental '.$type.' Documents'));
+ &escape($tabtitles{'supplemental'}{$type});
}
my $error = &editor($r,$coursenum,$coursedom,$folder,$allowed,'',$type);
if ($error) {
@@ -3156,7 +3224,7 @@ $lt{'comment'}:
$help{'Adding_Folders'}
@@ -3165,7 +3233,7 @@ value="$lt{'newf'}" /> $help{'Adding_Fol
$help{'Adding_External_Resource'}