--- loncom/interface/lonnavmaps.pm 2006/03/13 17:29:50 1.368
+++ loncom/interface/lonnavmaps.pm 2008/01/12 05:04:35 1.409
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Navigate Maps Handler
#
-# $Id: lonnavmaps.pm,v 1.368 2006/03/13 17:29:50 raeburn Exp $
+# $Id: lonnavmaps.pm,v 1.409 2008/01/12 05:04:35 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -31,15 +31,14 @@ package Apache::lonnavmaps;
use strict;
use GDBM_File;
-use Apache::Constants qw(:common :http);
use Apache::loncommon();
-use Apache::lonmenu();
use Apache::lonenc();
use Apache::lonlocal;
use Apache::lonnet;
use POSIX qw (floor strftime);
-use Data::Dumper; # for debugging, not always
use Time::HiRes qw( gettimeofday tv_interval );
+use LONCAPA;
+use DateTime();
# symbolic constants
sub SYMB { return 1; }
@@ -86,37 +85,9 @@ my %colormap =
$resObj->PARTIALLY_CORRECT => '#006600'
);
# And a special case in the nav map; what to do when the assignment
-# is not yet done and due in less then 24 hours
+# is not yet done and due in less than 24 hours
my $hurryUpColor = "#FF0000";
-sub launch_win {
- my ($mode,$script,$toplinkitems,$firsttime)=@_;
- my $result;
- if ($script ne 'no') {
- $result.='';
- }
- if ($mode eq 'link') {
- &add_linkitem($toplinkitems,'launchnav','launch_navmapwin()',
- "Launch navigation window");
- }
- return $result;
-}
-
sub close {
if ($env{'environment.remotenavmap'} ne 'on') { return ''; }
return(<header_only) {
- if ($env{'browser.mathml'}) {
- &Apache::loncommon::content_type($r,'text/xml');
- } else {
- &Apache::loncommon::content_type($r,'text/html');
- }
- $r->send_http_header;
- return OK;
- }
-
- # Send header, don't cache this page
- if ($env{'browser.mathml'}) {
- &Apache::loncommon::content_type($r,'text/xml');
- } else {
- &Apache::loncommon::content_type($r,'text/html');
- }
- &Apache::loncommon::no_cache($r);
-
- my %toplinkitems=();
- &add_linkitem(\%toplinkitems,'blank','',"Select Action");
- if ($ENV{QUERY_STRING} eq 'collapseExternal') {
- &Apache::lonnet::put('environment',{'remotenavmap' => 'off'});
- &Apache::lonnet::appenv('environment.remotenavmap' => 'off');
- my $menu=&Apache::lonmenu::reopenmenu();
- my $navstatus=&Apache::lonmenu::get_nav_status();
- if ($menu) {
- $menu=(<