');
# --------------------------------------------------------- Standard documents
if (($standard) && ($allowed) && (!$forcesupplement)) {
+ my $active = 'style="display: none;"';
+ if($activeClass == 0){
+ $active = 'style="display: block;"';
+ }
+ $r->print('
');
+ $r->print(&Apache::loncommon::help_open_topic('Docs_Adding_Course_Doc',
+ &mt('Editing the Table of Contents for your '.$type)));
my $folder=$env{'form.folder'};
if ($folder eq '' || $folder eq 'supplemental') {
$folder='default';
@@ -2892,16 +2929,16 @@ ERFORM
} else {
#$postexec='self.close();';
}
- $hadchanges=0;
- my $error = &editor($r,$coursenum,$coursedom,$folder,$allowed,
- $upload_output,$type);
- if ($error) {
- $r->print('
'.$error.'
');
- }
- if ($hadchanges) {
- &mark_hash_old();
- }
- &changewarning($r,$postexec);
+# $hadchanges=0;
+# my $error = &editor($r,$coursenum,$coursedom,$folder,$allowed,'',$type);
+# if ($error) {
+# $r->print('
'.$error.'
');
+# }
+# if ($hadchanges) {
+# &mark_hash_old();
+# }
+#
+# &changewarning($r,$postexec);
my $folderseq='/uploaded/'.$coursedom.'/'.$coursenum.'/default_'.time.
'.sequence';
my $pageseq = '/uploaded/'.$coursedom.'/'.$coursenum.'/default_'.time.
@@ -3119,12 +3156,28 @@ my $content='content';
my $navigation='navigation';
my $varcd = 'Main Course Documents';
$r->print(&generate_edit_table($tid,$content,$navigation,$varcd,\%namehash,\%orderhash));
+ $hadchanges=0;
+ my $error = &editor($r,$coursenum,$coursedom,$folder,$allowed,'',$type);
+ if ($error) {
+ $r->print('
'.$error.'
');
+ }
+ if ($hadchanges) {
+ &mark_hash_old();
+ }
+
+ &changewarning($r,'');
+$r->print('
');
}
if ($env{'form.pagepath'}) {
}
}
# ----------------------------------------------------- Supplemental documents
if (!$forcestandard) {
+ my $active = 'style="display: none;"';
+ if($activeClass == 1){
+ $active = 'style="display: block;"';
+ }
+ $r->print('
');
my $folder=$env{'form.folder'};
unless ($folder=~/^supplemental/) {
$folder='supplemental';
@@ -3134,10 +3187,6 @@ $r->print(&generate_edit_table($tid,$con
$env{'form.folderpath'} = 'supplemental&'.
&escape(&mt('Supplemental '.$type.' Documents'));
}
- my $error = &editor($r,$coursenum,$coursedom,$folder,$allowed,'',$type);
- if ($error) {
- $r->print('
'.$error.'
');
- }
if ($allowed) {
my $folderseq=
'/uploaded/'.$coursedom.'/'.$coursenum.'/supplemental_'.time.
@@ -3235,9 +3284,17 @@ my $navigation='navigation';
my $varscd = 'Supplemental Course Documents';
$r->print(&generate_edit_table($tid,$content,$navigation,$varscd,\%supnamehash,\%suporderhash));
-
+my $error = &editor($r,$coursenum,$coursedom,$folder,$allowed,'',$type);
+ if ($error) {
+ $r->print('
'.$error.'
');
+ }
+$r->print('
');
+$r->print(&generate_admin_options($containertag,$uploadtag,\%help,\%env));
+$r->print('