--- loncom/interface/londocs.pm 2009/12/20 02:09:00 1.411.2.3
+++ loncom/interface/londocs.pm 2010/01/13 14:32:57 1.412
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Documents
#
-# $Id: londocs.pm,v 1.411.2.3 2009/12/20 02:09:00 raeburn Exp $
+# $Id: londocs.pm,v 1.412 2010/01/13 14:32:57 wenzelju Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -41,7 +41,6 @@ use Apache::lonratedt();
use Apache::lonxml;
use Apache::lonclonecourse;
use Apache::lonnavmaps;
-use Apache::londocsgci;
use HTML::Entities;
use GDBM_File;
use Apache::lonlocal;
@@ -2619,15 +2618,6 @@ sub handler {
return OK if $r->header_only;
my $crstype = &Apache::loncommon::course_type();
- my $coursedom=$env{'course.'.$env{'request.course.id'}.'.domain'};
- if ($coursedom eq 'gcitest') {
- my $coursenum = $env{'course.'.$env{'request.course.id'}.'.num'};
- my $allowed=&Apache::lonnet::allowed('mdc',$env{'request.course.id'});
- if ($allowed) {
- &concept_test_builder($r,$coursedom,$coursenum);
- return OK;
- }
- }
# --------------------------------------------- Initialize help topics for this
foreach my $topic ('Adding_Course_Doc','Main_Course_Documents',
@@ -2982,9 +2972,9 @@ FUFORM
SEDFFORM
my @simpleeditdefaultforma = (
- { '
' => "$uploadtag$lt{'srch'}" },
- { '
' => "$lt{'impo'}$help{'Importing_LON-CAPA_Resource'}" },
- { '
' => "$lt{'book'}" },
+ { '
' => "$uploadtag$lt{'srch'}" },
+ { '
' => "$lt{'impo'}$help{'Importing_LON-CAPA_Resource'}" },
+ { '
' => "$lt{'book'}" },
);
$simpleeditdefaultform .= create_form_ul(create_list_elements(@simpleeditdefaultforma));
$simpleeditdefaultform .=(<
NGFFORM
@specialdocumentsforma=(
- {'
'=>$newpageform},
- {'
'=>$newsylform},
- {'
'=>$newgroupfileform},
+ {'
'=>$newpageform},
+ {'
'=>$newsylform},
+ {'
'=>$newgroupfileform},
);
}
- push @specialdocumentsforma, ({'
'=>$newnavform},
- {'
'=>$newsmppageform},
- {'
'=>$newsmpproblemform},
- {'
'=>$newdropboxform},
- {'
'=>$newexuploadform},
- {'
'=>$newbulform},
- {'
'=>$newaboutmeform},
- {'
'=>$newaboutsomeoneform},
- {'
'=>$newrosterform},);
+ push @specialdocumentsforma, ({'
'=>$newnavform},
+ {'
'=>$newsmppageform},
+ {'
'=>$newsmpproblemform},
+ {'
'=>$newdropboxform},
+ {'
'=>$newexuploadform},
+ {'
'=>$newbulform},
+ {'
'=>$newaboutmeform},
+ {'
'=>$newaboutsomeoneform},
+ {'
'=>$newrosterform},);
$specialdocumentsform = create_form_ul(create_list_elements(@specialdocumentsforma));
@@ -3302,9 +3292,9 @@ if($env{'form.pagepath'}) {
}
my @tools = (
- {'
'=>$extresourcesform},
- {'
'=>$imspform},
- {'
'=>$recoverform},
+ {'
'=>$extresourcesform},
+ {'
'=>$imspform},
+ {'
'=>$recoverform},
);
my %orderhash = (
@@ -3419,9 +3409,9 @@ SNAMFORM
my @specialdocs = (
- {'
'=>$supnewextform},
- {'
'=>$supnewsylform},
- {'
'=>$supnewaboutmeform},
+ {'
'=>$supnewextform},
+ {'
'=>$supnewsylform},
+ {'
'=>$supnewaboutmeform},
);
my %suporderhash = (
'00' => ['Supnewfolder', $supnewfolderform],
@@ -3476,22 +3466,24 @@ sub generate_admin_options {
'vc' => 'Verify Content',
'cv' => 'Check/Set Resource Versions',
'ls' => 'List Symbs',
- 'sl' => 'Show Log'
+ 'sl' => 'Show Log',
+ 'imse' => 'IMS Export',
+ 'dcd' => 'Dump Course DOCS to Construction Space: available on other servers'
);
my %help = %{$help_ref};
my %env = %{$env_ref};
my $dumpbut=&dumpbutton();
my $exportbut=&exportbutton();
my @list = (
- {'
'=>"$lt{'vc'}$help{'Verify_Content'}"},
- {'
'=>"$lt{'cv'}$help{'Check_Resource_Versions'}"},
+ {'
'=>"$lt{'vc'}$help{'Verify_Content'}"},
+ {'
'=>"$lt{'cv'}$help{'Check_Resource_Versions'}"},
);
if($dumpbut ne ''){
- push @list, {'
'=>$dumpbut};
+ push @list, {'
'=>$dumpbut};
}
- push @list, ({'
'=>$exportbut},
- {'
'=>"$lt{'ls'}"},
- {'
'=>"$lt{'sl'}"},
+ push @list, ({'
'=>$exportbut},
+ {'
'=>"$lt{'ls'}"},
+ {'
'=>"$lt{'sl'}"},
);
return '';
@@ -3542,54 +3534,6 @@ sub generate_edit_table {
return $form;
}
-sub concept_test_builder {
- my ($r,$cdom,$cnum) = @_;
- my $js = '
-
-';
- my $starthash = {
- add_entries => {'onload' => "javascript:setInitialVisibility();"},
- };
-
- $r->print(&Apache::loncommon::start_page('Assemble Test',$js,$starthash));
- &Apache::lonhtmlcommon::clear_breadcrumbs();
- &Apache::lonhtmlcommon::add_breadcrumb
- ({href=>'/adm/coursedocs',
- text=>"Assemble Test"});
- &Apache::londocsgci::setdefaults();
- if ($env{'form.phase'} eq 'storemap') {
- &Apache::lonhtmlcommon::add_breadcrumb
- ({href=>'/adm/coursedocs?phase=storemap',
- text=>"Validate Test"});
- &Apache::londocsgci::evaluate();
- $r->print(&Apache::lonhtmlcommon::breadcrumbs
- ('Build Concept Test','Concept_Test_Assembly'));
- $r->print(&Apache::londocsgci::store('edit',$cdom,$cnum));
- } elsif ($env{'form.phase'} eq 'storeparms') {
- &Apache::lonhtmlcommon::add_breadcrumb
- ({href=>'/adm/coursedocs?phase=storeparms',
- text=>"Set Availability"});
- $r->print(&Apache::lonhtmlcommon::breadcrumbs
- ('Build Concept Test','Concept_Test_Assembly'));
- $r->print(&Apache::londocsgci::store_dates_parms($cdom,$cnum));
- $r->print(&Apache::loncommon::end_page());
- return;
- } else {
- $r->print(&Apache::lonhtmlcommon::breadcrumbs
- ('Build Concept Test','Concept_Test_Assembly'));
- }
- &Apache::londocsgci::load();
- &Apache::londocsgci::listresources($r,'edit',$cdom,$cnum);
- $r->print(&Apache::loncommon::end_page());
- return;
-}
-
sub editing_js {
my ($udom,$uname) = @_;
my $now = time();