[LON-CAPA-cvs] cvs: loncom /homework essayresponse.pm
ng
lon-capa-cvs@mail.lon-capa.org
Fri, 26 Jul 2002 20:27:33 -0000
ng Fri Jul 26 16:27:33 2002 EDT
Modified files:
/loncom/homework essayresponse.pm
Log:
Slightly modification - it does not save the collaborator list if it has not
been changed since the last submission.
Index: loncom/homework/essayresponse.pm
diff -u loncom/homework/essayresponse.pm:1.11 loncom/homework/essayresponse.pm:1.12
--- loncom/homework/essayresponse.pm:1.11 Thu Jul 25 16:51:39 2002
+++ loncom/homework/essayresponse.pm Fri Jul 26 16:27:33 2002
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# essay (ungraded) style responses
#
-# $Id: essayresponse.pm,v 1.11 2002/07/25 20:51:39 ng Exp $
+# $Id: essayresponse.pm,v 1.12 2002/07/26 20:27:33 ng Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -62,7 +62,10 @@
my $id = &Apache::response::start_response($parstack,$safeeval);
my $collaborators = $ENV{'form.HWCOL'.$id};
if ($collaborators =~ /[^\s]/) {
- $Apache::lonhomework::results{"resource.$part.$id.collaborators"}=$collaborators;
+ my $previous_list= &HTML::Entities::encode($Apache::lonhomework::history{"resource.$part.$id.collaborators"});
+
+ $Apache::lonhomework::results{"resource.$part.$id.collaborators"}=$collaborators
+ if ($collaborators ne $previous_list);
}
if ( $target eq 'grade' ) {
if ( defined $ENV{'form.submitted'}) {