[LON-CAPA-cvs] cvs: loncom(version_2_10_X) /homework inputtags.pm

raeburn raeburn@source.lon-capa.org
Tue, 09 Nov 2010 17:41:47 -0000


raeburn		Tue Nov  9 17:41:47 2010 EDT

  Modified files:              (Branch: version_2_10_X)
    /loncom/homework	inputtags.pm 
  Log:
  - Backport 1.273.
  
  
Index: loncom/homework/inputtags.pm
diff -u loncom/homework/inputtags.pm:1.271 loncom/homework/inputtags.pm:1.271.2.1
--- loncom/homework/inputtags.pm:1.271	Sun Sep  5 20:57:42 2010
+++ loncom/homework/inputtags.pm	Tue Nov  9 17:41:47 2010
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # input  definitons
 #
-# $Id: inputtags.pm,v 1.271 2010/09/05 20:57:42 raeburn Exp $
+# $Id: inputtags.pm,v 1.271.2.1 2010/11/09 17:41:47 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -576,6 +576,7 @@
     }
     foreach my $name (sort(keys(%okfiles))) {
         if (ref($okfiles{$name}) eq 'ARRAY') {
+            my $num = 0;
             foreach my $url (@{$okfiles{$name}}) {
                 if (ref($rows{$url}) eq 'HASH') {
                     my $link = $rows{$url}{link};
@@ -592,7 +593,8 @@
                         if ($Apache::inputtags::status[-1] eq 'CAN_ANSWER') {
                             $result .=
                                  '<td valign="bottom"><input type="checkbox" name="HWFILE'.$jspart.'_'.$id.'_delete"'.
-                                 ' value="'.$portfile.'" /></td>'."\n";
+                                 ' value="'.$portfile.'" id="HWFILE'.$jspart.'_'.$id.'_'.$num.'_delete" /></td>'."\n";
+                            $num ++;
                         }
                         my $showname = $rows{$url}{path}.$name;
                         if ($legacy{$url}) {
@@ -610,7 +612,9 @@
         }
     }
     if ($header_shown) {
-        $result .= &Apache::loncommon::end_data_table();
+        $result .= &Apache::loncommon::end_data_table().
+                   '<br /><span class="LC_warning">'.
+                   &mt('Items checked for deletion will not be included amongst the files evaluated when your submission is graded.').'</span>';
     }
     if (@bad_file_list) {
         my $bad_files = '<span class="LC_filename">'.