[LON-CAPA-cvs] cvs: loncom /homework inputtags.pm

albertel lon-capa-cvs@mail.lon-capa.org
Tue, 19 Oct 2004 15:24:33 -0000


albertel		Tue Oct 19 11:24:33 2004 EDT

  Modified files:              
    /loncom/homework	inputtags.pm 
  Log:
  - wasn't updating awarded when doing scantron regrading
  
  
Index: loncom/homework/inputtags.pm
diff -u loncom/homework/inputtags.pm:1.151 loncom/homework/inputtags.pm:1.152
--- loncom/homework/inputtags.pm:1.151	Mon Oct  4 14:15:22 2004
+++ loncom/homework/inputtags.pm	Tue Oct 19 11:24:32 2004
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # input  definitons
 #
-# $Id: inputtags.pm,v 1.151 2004/10/04 18:15:22 albertel Exp $
+# $Id: inputtags.pm,v 1.152 2004/10/19 15:24:32 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -570,7 +570,8 @@
 	} elsif ( $award eq 'INCORRECT' ) {
 	    $Apache::lonhomework::results{"resource.$id.tries"} =
 		$Apache::lonhomework::history{"resource.$id.tries"} + 1;
-	    if (lc($Apache::lonhomework::problemstatus) eq 'no') {
+	    if (lc($Apache::lonhomework::problemstatus) eq 'no' ||
+		$Apache::lonhomework::scantronmode) {
 		$Apache::lonhomework::results{"resource.$id.awarded"} = 0;
 	    }
 	    $Apache::lonhomework::results{"resource.$id.solved"} =
@@ -589,7 +590,8 @@
 	} else {
 	    $Apache::lonhomework::results{"resource.$id.solved"} =
 		'incorrect_attempted';
-	    if (lc($Apache::lonhomework::problemstatus) eq 'no') {
+	    if (lc($Apache::lonhomework::problemstatus) eq 'no' ||
+		$Apache::lonhomework::scantronmode) {
 		$Apache::lonhomework::results{"resource.$id.tries"} =
 		    $Apache::lonhomework::history{"resource.$id.tries"} + 1;
 		$Apache::lonhomework::results{"resource.$id.awarded"} = 0;