version 1.2, 2005/04/07 03:58:02
|
version 1.3, 2005/04/07 04:12:31
|
Line 30 package Apache::lonwhatsnew;
|
Line 30 package Apache::lonwhatsnew;
|
use strict; |
use strict; |
use lib qw(/home/httpd/lib/perl); |
use lib qw(/home/httpd/lib/perl); |
use Apache::lonnet; |
use Apache::lonnet; |
use Apache::loncommon; |
use Apache::loncommon(); |
use Apache::lonhtmlcommon; |
use Apache::lonhtmlcommon(); |
use Apache::lonlocal; |
use Apache::lonlocal; |
use Apache::loncoursedata; |
use Apache::loncoursedata(); |
use Apache::lonnavmaps; |
use Apache::lonnavmaps(); |
use Apache::Constants qw(:common :http); |
use Apache::Constants qw(:common :http); |
use Time::Local; |
use Time::Local; |
|
|
Line 177 sub display_nav_box {
|
Line 177 sub display_nav_box {
|
#------------------------------- |
#------------------------------- |
|
|
sub display_header{ |
sub display_header{ |
|
my $html=&Apache::lonxml::xmlbegin(); |
my $bodytag=&Apache::loncommon::bodytag('Course Action Items'); |
my $bodytag=&Apache::loncommon::bodytag('Course Action Items'); |
return(<<ENDHEAD); |
return(<<ENDHEAD); |
<html> |
$html |
<head> |
<head> |
<title>Course Action Items</title> |
<title>Course Action Items</title> |
</head> |
</head> |
Line 256 END
|
Line 257 END
|
if ($feedurl=~m|^/adm/wrapper/adm/.*/bulletinboard$|) { |
if ($feedurl=~m|^/adm/wrapper/adm/.*/bulletinboard$|) { |
$feedurl=~s|^/adm/wrapper||; |
$feedurl=~s|^/adm/wrapper||; |
} |
} |
my $unreadnum = keys %{$unread{$ressymb}}; |
my $unreadnum = keys(%{$unread{$ressymb}}); |
$unreadnum = $unreadnum - 2; |
$unreadnum = $unreadnum - 2; |
if ($unreadnum > 0) { |
if ($unreadnum > 0) { |
if ($rowNum %2 == 1) { |
if ($rowNum %2 == 1) { |
Line 416 sub getitems {
|
Line 417 sub getitems {
|
my @discussions = (); |
my @discussions = (); |
my ($classlist,$keylist) = &Apache::loncoursedata::get_classlist(); |
my ($classlist,$keylist) = &Apache::loncoursedata::get_classlist(); |
|
|
foreach (keys %lastread) { |
foreach my $key (keys(%lastread)) { |
my $key = $_; |
my $newkey = $key; |
$key =~ s/_lastread$//; |
$newkey =~ s/_lastread$//; |
$lastreadtime{$key} = $lastread{$_}; |
$lastreadtime{$newkey} = $lastread{$key}; |
} |
} |
foreach my $resource (@allres) { |
foreach my $resource (@allres) { |
my $result = ''; |
my $result = ''; |
Line 469 sub getitems {
|
Line 470 sub getitems {
|
my ($map,$ind,$url)=&Apache::lonnet::decode_symb($symb); |
my ($map,$ind,$url)=&Apache::lonnet::decode_symb($symb); |
my ($partlist,$handgrade,$responseType) = &Apache::grades::response_type($url,$symb); |
my ($partlist,$handgrade,$responseType) = &Apache::grades::response_type($url,$symb); |
foreach my $student (keys(%$classlist)) { |
foreach my $student (keys(%$classlist)) { |
my ($uname,$udom) = split/:/,$student; |
my ($uname,$udom) = split(/:/,$student); |
my %status=&Apache::grades::student_gradeStatus($url,$symb,$udom,$uname,$partlist); |
my %status=&Apache::grades::student_gradeStatus($url,$symb,$udom,$uname,$partlist); |
my $submitted = 0; |
my $submitted = 0; |
my $graded = 0; |
my $graded = 0; |
Line 510 sub getmail {
|
Line 511 sub getmail {
|
my ($newmsgs,$critmsgs) = @_; |
my ($newmsgs,$critmsgs) = @_; |
# Check for unread mail in course |
# Check for unread mail in course |
my $msgcount = 0; |
my $msgcount = 0; |
my @msgids = sort split(/\&/,&Apache::lonnet::reply |
|
('keys:'.$ENV{'user.domain'}.':'. |
my @messages = &Apache::lonnet::getkeys('nohist_email'); |
$ENV{'user.name'}.':nohist_email', |
foreach my $message (@messages) { |
$ENV{'user.home'})); |
my $msgid=&Apache::lonnet::escape($message); |
foreach my $msgid (@msgids) { |
|
my ($sendtime,$shortsubj,$fromname,$fromdom,$fromcid,$status)= |
my ($sendtime,$shortsubj,$fromname,$fromdom,$fromcid,$status)= |
&Apache::lonmsg::unpackmsgid($msgid); |
&Apache::lonmsg::unpackmsgid($msgid); |
if ($fromcid eq $ENV{'request.course.id'}) { |
if ($fromcid eq $ENV{'request.course.id'}) { |
Line 539 sub getmail {
|
Line 539 sub getmail {
|
my %what=&Apache::lonnet::dump('critical'); |
my %what=&Apache::lonnet::dump('critical'); |
my $result = ''; |
my $result = ''; |
my $critmsgcount = 0; |
my $critmsgcount = 0; |
foreach my $msgid (sort keys %what) { |
foreach my $msgid (sort(keys(%what))) { |
my ($sendtime,$shortsubj,$fromname,$fromdom,$fromcid,$status)= |
my ($sendtime,$shortsubj,$fromname,$fromdom,$fromcid,$status)= |
&Apache::lonmsg::unpackmsgid($_); |
&Apache::lonmsg::unpackmsgid($_); |
if ($fromcid eq $ENV{'request.course.id'}) { |
if ($fromcid eq $ENV{'request.course.id'}) { |