[LON-CAPA-cvs] cvs: loncom(version_2_10_X) /homework inputtags.pm
raeburn
raeburn@source.lon-capa.org
Sat, 05 Mar 2011 23:01:36 -0000
raeburn Sat Mar 5 23:01:36 2011 EDT
Modified files: (Branch: version_2_10_X)
/loncom/homework inputtags.pm
Log:
- Backport 1.279, 1.280, 1.281.
Index: loncom/homework/inputtags.pm
diff -u loncom/homework/inputtags.pm:1.271.2.5 loncom/homework/inputtags.pm:1.271.2.6
--- loncom/homework/inputtags.pm:1.271.2.5 Thu Jan 6 22:56:42 2011
+++ loncom/homework/inputtags.pm Sat Mar 5 23:01:35 2011
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# input definitons
#
-# $Id: inputtags.pm,v 1.271.2.5 2011/01/06 22:56:42 raeburn Exp $
+# $Id: inputtags.pm,v 1.271.2.6 2011/03/05 23:01:35 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1524,6 +1524,16 @@
) {
my $txt_correct = &mt('Correct');
+ my $awarded = $Apache::lonhomework::history{"$prefix.awarded"};
+ if ($awarded < 1 && $awarded > 0) {
+ $txt_correct=&mt('Partially Correct');
+ } elsif ($awarded < 1) {
+ if ($awarded eq '') {
+ $txt_correct='';
+ } else {
+ $txt_correct=&mt('Incorrect');
+ }
+ }
$message =~ s{(<td.*?>)(.*?)(</td>)}
{$1 <strong>$txt_correct</strong>. $3}s;
}