--- rat/lonratparms.pm 2006/04/04 15:32:12 1.24 +++ rat/lonratparms.pm 2011/12/08 22:11:48 1.29 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Set parameters inside of the RAT # -# $Id: lonratparms.pm,v 1.24 2006/04/04 15:32:12 albertel Exp $ +# $Id: lonratparms.pm,v 1.29 2011/12/08 22:11:48 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -80,22 +80,16 @@ sub handler { my %lt=&Apache::lonlocal::texthash('pa' => 'Parameter', 'de' => 'Default', 'va' => 'Value', - 'se' => 'Set'); + 'se' => 'Set?'); my $js = (< - function pclose() { - parmwin=window.open("/adm/rat/empty.html","LONCAPAparms", - "height=350,width=350,scrollbars=no,menubar=no"); - parmwin.close(); - } - $pjump_def function stpr() { eval("document.parameters."+document.parameters.pres_marker.value+ ".value=document.parameters.pres_value.value"); - pclose(); + modalWindow.close(); } @@ -120,11 +114,11 @@ ENDHEADER $r->print(< - - - - - + + + +
$lt{'pa'}$lt{'de'}$lt{'va'}$lt{'se'}?
+ ENDDOCUMENT ### %display=&Apache::lonlocal::texthash(%display); @@ -134,17 +128,17 @@ ENDDOCUMENT # Should if(defined($value{$key})) be if(exists($value{$key})) ? if (defined($value{$key})) { $cur=$value{$key}; }; $r->print(<<"END"); - + -'); + if ($value{$key}) { $r->print(' checked="checked"'); } + $r->print(' />'); } $r->print('
$lt{'pa'}$lt{'de'}$lt{'va'}$lt{'se'}
$display{$key}
$key
$display{$key}
$key
 $content{$key}  +  $enter print(' checked'); } - $r->print('>

- '. + '. &Apache::loncommon::end_page()); return OK; } @@ -152,3 +146,33 @@ END 1; __END__ + + +=head1 NAME + +Apache::lonratparams + +=head1 SYNOPSIS + +Handler to set resource parameters inside of +the RAT based on metadata. + +This is part of the LearningOnline Network with CAPA project +described at http://www.lon-capa.org. + +=head1 HANDLER SUBROUTINE + +handler() + +=head1 OTHER SUBROUTINES + +=over + +=item * + +none + +=back + +=cut +