--- loncom/interface/lonnavmaps.pm 2005/12/20 16:43:27 1.355
+++ loncom/interface/lonnavmaps.pm 2007/11/20 17:53:46 1.406
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Navigate Maps Handler
#
-# $Id: lonnavmaps.pm,v 1.355 2005/12/20 16:43:27 www Exp $
+# $Id: lonnavmaps.pm,v 1.406 2007/11/20 17:53:46 albertel 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=(<