[LON-CAPA-cvs] cvs: loncom /interface lonparmset.pm

www lon-capa-cvs@mail.lon-capa.org
Mon, 17 Jul 2006 17:23:24 -0000


www		Mon Jul 17 13:23:24 2006 EDT

  Modified files:              
    /loncom/interface	lonparmset.pm 
  Log:
  When default values were set, would set parameters you don't want to have set.
  
  
Index: loncom/interface/lonparmset.pm
diff -u loncom/interface/lonparmset.pm:1.324 loncom/interface/lonparmset.pm:1.325
--- loncom/interface/lonparmset.pm:1.324	Fri Jul 14 15:35:37 2006
+++ loncom/interface/lonparmset.pm	Mon Jul 17 13:23:24 2006
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Handler to set parameters for assessments
 #
-# $Id: lonparmset.pm,v 1.324 2006/07/14 19:35:37 www Exp $
+# $Id: lonparmset.pm,v 1.325 2006/07/17 17:23:24 www Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -2589,15 +2589,6 @@
 		$oldpart=$part;
 	    }
 #
-# Preset defaults?
-#
-            my ($hour,$min,$sec,$val)=('','','','');
-	    unless ($$resourcedata{$thiskey}) {
-		my ($parmname)=($thiskey=~/\.(\w+)$/);
-		($hour,$min,$sec,$val)=&preset_defaults($parmname);
-	    }
-
-#
 # Ready to print
 #
 	    $r->print(&tablestart().
@@ -2613,7 +2604,7 @@
 			  &Apache::lonhtmlcommon::date_setter('parmform',
 							      $jskey,
 						      $$resourcedata{$thiskey},
-							      '',1,'','',$hour,$min,$sec).
+							      '',1,'','').
 '<input type="hidden" name="datepointer_'.$thiskey.'" value="'.$jskey.'" />'.
 &date_sanity_info($$resourcedata{$thiskey})
 			  );
@@ -2621,8 +2612,6 @@
 		my $showval;
 		if (defined($$resourcedata{$thiskey})) {
 		    $showval=$$resourcedata{$thiskey};
-		} else {
-		    $showval=$val;
 		}
 		$r->print('<label><input type="radio" name="set_'.$thiskey.
 			  '" value="yes"');
@@ -2640,8 +2629,6 @@
 		my $showval;
 		if (defined($$resourcedata{$thiskey})) {
 		    $showval=$$resourcedata{$thiskey};
-		} else {
-		    $showval=$val;
 		}
 		$r->print('<input type="text" name="set_'.$thiskey.'" value="'.
 			  $showval.'">');