[LON-CAPA-cvs] cvs: loncom /homework bridgetask.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Wed, 28 Jun 2006 21:46:53 -0000
albertel Wed Jun 28 17:46:53 2006 EDT
Modified files:
/loncom/homework bridgetask.pm
Log:
- properly handle grading of <Dimension> nested inside of <QuestionText>
Index: loncom/homework/bridgetask.pm
diff -u loncom/homework/bridgetask.pm:1.179 loncom/homework/bridgetask.pm:1.180
--- loncom/homework/bridgetask.pm:1.179 Fri Jun 23 21:28:17 2006
+++ loncom/homework/bridgetask.pm Wed Jun 28 17:46:53 2006
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# definition of tags that give a structure to a document
#
-# $Id: bridgetask.pm,v 1.179 2006/06/24 01:28:17 albertel Exp $
+# $Id: bridgetask.pm,v 1.180 2006/06/28 21:46:53 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -372,6 +372,8 @@
@Apache::scripttag::parser_env = @old_env;
if ($args->{'delayed_dim_results'}) {
my $dim = &get_dim_id();
+ &Apache::lonxml::debug(" tossing out $result ");
+ &Apache::lonxml::debug(" usining out $dim 's ". $dimension{$dim}{'result'});
return $dimension{$dim}{'result'};
}
return $result;
@@ -2221,8 +2223,8 @@
&nested_parse(\$dimension{$dim}{$instance.'.text'},[@_]);
$result.=
&nested_parse(\$dimension{$dim}{'questiontext'},[@_],
- {'set_dim_id' => undef,
- 'delay_dim_results' => 1});
+ {'set_dim_id' => undef,
+ 'delayed_dim_results' => 1});
foreach my $id (@{$dimension{$dim}{$instance.'.criterias'}},
@{$dimension{$dim}{'criterias'}} ) {
my $type = $dimension{$dim}{'criteria.'.$id.'.type'};
@@ -2259,7 +2261,7 @@
$result.=&grading_history($version,$dim,$id);
$last_link=$link;
}
- if (&delay_result()) {
+ if (&nest()) {
&Apache::lonxml::debug(" for $dim stashing results into ".$dimension{$dim}{'nested'});
$dimension{$dimension{$dim}{'nested'}}{'result'}.=$result;
undef($result);