[LON-CAPA-cvs] cvs: loncom /interface lonparmset.pm
banghart
lon-capa-cvs@mail.lon-capa.org
Fri, 14 Oct 2005 17:05:45 -0000
banghart Fri Oct 14 13:05:45 2005 EDT
Modified files:
/loncom/interface lonparmset.pm
Log:
Display metadata like metadata (not in table)
Change some titles.
Index: loncom/interface/lonparmset.pm
diff -u loncom/interface/lonparmset.pm:1.259 loncom/interface/lonparmset.pm:1.260
--- loncom/interface/lonparmset.pm:1.259 Fri Oct 14 00:25:56 2005
+++ loncom/interface/lonparmset.pm Fri Oct 14 13:05:44 2005
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Handler to set parameters for assessments
#
-# $Id: lonparmset.pm,v 1.259 2005/10/14 04:25:56 banghart Exp $
+# $Id: lonparmset.pm,v 1.260 2005/10/14 17:05:44 banghart Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -2760,28 +2760,29 @@
$options = 'active,stuadd';
$values = 'Type a list of values separated by commas.';
}
+ $output.='<strong>'.$field_text.':</strong>';
+ $output.='<input name="'.$field_name.'_values" type="text" value="'.$values.'" /><br />';
if ($options =~ m/active/) {
$checked = ' checked="checked" ';
} else {
$checked = ' ';
}
- $output.='<tr><td><center><input type="checkbox" name="'.$field_name.'_active" value="yes"'.$checked.' /></center></td>';
- $output.='<td><strong>'.$field_text.'</strong></td>';
- $output.='<td><input name="'.$field_name.'_values" type="text" value="'.$values.'" /></td>';
+ $output.=' <input type="checkbox" name="'.$field_name.'_active" value="yes"'.$checked.' />';
+ $output.='Active <br />';
if ($options =~ m/onlyone/) {
$checked = ' checked="checked" ';
} else {
$checked = ' ';
}
- $output.='<td><center><input type="checkbox" name="'.$field_name.'_onlyone" value="yes"'.$checked.' /></center></td>';
+ $output.=' <input type="checkbox" name="'.$field_name.'_onlyone" value="yes"'.$checked.' />';
+ $output.='Student may select only one choice <br />';
if ($options =~ m/stuadd/) {
$checked = ' checked="checked" ';
} else {
$checked = ' ';
}
- $output.='<td><input type="checkbox" name="'.$field_name.'_stuadd" value="yes"'.$checked.' /></td>';
-
- $output.='</tr>';
+ $output.=' <input type="checkbox" name="'.$field_name.'_stuadd" value="yes"'.$checked.' />';
+ $output.='Student may type choices <br />';
return ($output);
}
@@ -2793,11 +2794,11 @@
my $put_result;
$r->print(&Apache::lonxml::xmlbegin());
$r->print('<head>
- <title>LON-CAPA Set Portfolio Metadata</title>
+ <title>LON-CAPA Restrict Metadata</title>
</head>');
- $r->print(&Apache::loncommon::bodytag('Set Portfolio Metadata'));
+ $r->print(&Apache::loncommon::bodytag('Restrict Metadata'));
$r->print(&Apache::lonhtmlcommon::breadcrumbs(undef,
- 'Set Portfolio Metadata'));
+ 'Restrict Metadata'));
my $dom = $env{'course.'.$env{'request.course.id'}.'.domain'};
my $crs = $env{'course.'.$env{'request.course.id'}.'.num'};
my $key_base = $env{'course.'.$env{'request.course.id'}.'.'};
@@ -2827,28 +2828,19 @@
}
}
}
-
}
&Apache::lonnet::coursedescription($env{'request.course.id'});
my %metadata_fields = &Apache::lonmeta::fieldnames('portfolio');
-
foreach my $field (sort(keys(%metadata_fields))) {
$output.= &output_row($r, $field, $metadata_fields{$field});
}
$r->print(<<ENDenv);
<form method="post" action="/adm/parmset?action=setrestrictmeta" name="form">
-
<p>
- <table border=2>
- <tr><th>Active</th><th>Metadata Item</th><th>Values</th><th>Only One Choice</th><th>Student Can Add Choices</th></tr>
$output
- </table>
<input type="submit" name="restrictmeta" value="Update Metadata Restrictions">
</form>
-
ENDenv
-
-
$r->print('</body>
</html>');
return 'ok';