[LON-CAPA-cvs] cvs: loncom(version_1_3_X) /homework imageresponse.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Mon, 31 Jan 2005 22:47:43 -0000
albertel Mon Jan 31 17:47:43 2005 EDT
Modified files: (Branch: version_1_3_X)
/loncom/homework imageresponse.pm
Log:
- backport 1.60
Index: loncom/homework/imageresponse.pm
diff -u loncom/homework/imageresponse.pm:1.58 loncom/homework/imageresponse.pm:1.58.2.1
--- loncom/homework/imageresponse.pm:1.58 Tue Dec 7 20:00:41 2004
+++ loncom/homework/imageresponse.pm Mon Jan 31 17:47:43 2005
@@ -2,7 +2,7 @@
# The LearningOnline Network with CAPA
# image click response style
#
-# $Id: imageresponse.pm,v 1.58 2004/12/08 01:00:41 albertel Exp $
+# $Id: imageresponse.pm,v 1.58.2.1 2005/01/31 22:47:43 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -270,10 +270,15 @@
$temp++;
}
}
+ my $responsestr="$x:$y";
+ my $part=$Apache::inputtags::part;
+ my $id = $Apache::inputtags::response['-1'];
+ my %previous=&Apache::response::check_for_previous($responsestr,$part,$id);
if ($result
&& $Apache::lonhomework::type eq 'survey') { $result='SUBMITTED'; }
- $Apache::lonhomework::results{"resource.$Apache::inputtags::part.$id.submission"}="$x:$y";
- $Apache::lonhomework::results{"resource.$Apache::inputtags::part.$id.awarddetail"}=$result;
+ &Apache::response::handle_previous(\%previous,$result);
+ $Apache::lonhomework::results{"resource.$part.$id.submission"}=$responsestr;
+ $Apache::lonhomework::results{"resource.$part.$id.awarddetail"}=$result;
return '';
}