[LON-CAPA-cvs] cvs: rat / lonratedt.pm

www lon-capa-cvs@mail.lon-capa.org
Sat, 24 Apr 2004 15:05:16 -0000


www		Sat Apr 24 11:05:16 2004 EDT

  Modified files:              
    /rat	lonratedt.pm 
  Log:
  One resource can have more than one parameter ... lonratedt.pm was only
  remembering the last.
  
  
Index: rat/lonratedt.pm
diff -u rat/lonratedt.pm:1.54 rat/lonratedt.pm:1.55
--- rat/lonratedt.pm:1.54	Fri Apr 23 18:34:15 2004
+++ rat/lonratedt.pm	Sat Apr 24 11:05:16 2004
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Edit Handler for RAT Maps
 #
-# $Id: lonratedt.pm,v 1.54 2004/04/23 22:34:15 www Exp $
+# $Id: lonratedt.pm,v 1.55 2004/04/24 15:05:16 www Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -25,10 +25,7 @@
 #
 # http://www.lon-capa.org/
 #
-# (TeX Content Handler
-#
-# 05/29/00,05/30 Gerd Kortemeyer)
-# 7/1,6/30 Gerd Kortemeyer
+
 
 package Apache::lonratedt;
 
@@ -206,7 +203,11 @@
             $links[$number]=$content;
         }
         if ($command eq 'objparms') {
-	    $resparms[$number]=$content;
+	    if ($resparms[$number]) {
+		$resparms[$number].='&&&'.$content;
+	    } else {
+		$resparms[$number]=$content;
+	    }
         }
     }
 # ------------------------------------------------------- Is this a linear map?
@@ -515,7 +516,11 @@
 	    $output.='<&>objcont<:>'.$order[$i].'<:>'.$resources[$order[$i]];
         }
 	if (defined($resparms[$order[$i]])) {
-	    $output.='<&>objparms<:>'.$order[$i].'<:>'.$resparms[$order[$i]];
+	    foreach (split('&&&',$resparms[$order[$i]])) {
+		if ($_) {
+		    $output.='<&>objparms<:>'.$order[$i].'<:>'.$_;
+		}
+	    }
 	}
         if (defined($order[$i+1])) {
 	    if (defined($resources[$order[$i+1]])) {