--- loncom/interface/lonparmset.pm 2011/12/08 21:37:46 1.518 +++ loncom/interface/lonparmset.pm 2011/12/15 01:21:41 1.519 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Handler to set parameters for assessments # -# $Id: lonparmset.pm,v 1.518 2011/12/08 21:37:46 www Exp $ +# $Id: lonparmset.pm,v 1.519 2011/12/15 01:21:41 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1394,6 +1394,7 @@ sub lookUpTableParameter { 'maxcollaborators' => 'misc', 'scoreformat' => 'misc', 'lenient' => 'grading', + 'retrypartial' => 'tries', ); } @@ -2145,7 +2146,7 @@ sub assessparms { } } } - } elsif ($markers[$i] =~ /_(type|lenient)\&\d+$/) { + } elsif ($markers[$i] =~ /_(type|lenient|retrypartial)\&\d+$/) { $name = $1; $needsrelease = $Apache::lonnet::needsrelease{"parameter:$name:$values[$i]"}; @@ -2807,6 +2808,10 @@ sub storedata { $name = 'type'; } elsif ($typeof eq 'string_lenient') { $name = 'lenient'; + } elsif ($typeof eq 'string_yesno') { + if ($thiskey =~ /\.retrypartial$/) { + $name = 'retrypartial'; + } } if ($name ne '') { my ($needsrelease,$needsnewer); @@ -3155,7 +3160,8 @@ sub string_selector { my %skiptype; if (($thistype eq 'string_questiontype') || - ($thistype eq 'string_lenient')) { + ($thistype eq 'string_lenient') || + ($name eq 'retrypartial')) { my ($got_chostname,$chostname,$cmajor,$cminor); foreach my $possibilities (@{ $strings{$thistype} }) { next unless (ref($possibilities) eq 'ARRAY'); @@ -4606,8 +4612,9 @@ sub oldversion_warning { my ($name,$value,$chostname,$cmajor,$cminor,$needsrelease) = @_; my $desc; my %stringtypes = ( - type => 'string_questiontype', - lenient => 'string_lenient' + type => 'string_questiontype', + lenient => 'string_lenient', + retrypartial => 'string_yesno', ); if (exists($stringtypes{$name})) { if (ref($strings{$stringtypes{$name}}) eq 'ARRAY') {