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

bisitz bisitz at source.lon-capa.org
Fri Jan 17 12:10:13 EST 2014


bisitz		Fri Jan 17 17:10:13 2014 EDT

  Modified files:              
    /loncom/interface	lonevaluate.pm 
  Log:
  Help students to easily find out which fields are required and which not.
  - Add marker to all required fields and display info text to explain.
  - Improve/consistent layout of feedback if not correctly filled in.
  
  
  
Index: loncom/interface/lonevaluate.pm
diff -u loncom/interface/lonevaluate.pm:1.29 loncom/interface/lonevaluate.pm:1.30
--- loncom/interface/lonevaluate.pm:1.29	Fri Sep  4 16:12:09 2009
+++ loncom/interface/lonevaluate.pm	Fri Jan 17 17:10:12 2014
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Evaluate
 #
-# $Id: lonevaluate.pm,v 1.29 2009/09/04 16:12:09 bisitz Exp $
+# $Id: lonevaluate.pm,v 1.30 2014/01/17 17:10:12 bisitz Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -125,7 +125,7 @@
            );
            return OK;
         } else {
-            $warning=&mt('Please fill out all fields below.');
+            $warning=&mt('Please fill out all required fields below!');
         }
    
     }
@@ -173,6 +173,7 @@
 
     %lt=&Apache::lonlocal::texthash(
        'pleaserank' => 'Please rank the following criteria:',
+       'required'   => '(All fields marked with * are required.)',
        'correct'    => 'The material appears to be correct',
        'helpful'    => 'The material is helpful',
        'depth'      => 'The material is covered with sufficient depth',
@@ -183,22 +184,32 @@
     );
     $r->print(
         $start_page
-       .'<h2>'.$title.'</h2>'
-       .'<p class="LC_warning">'.$warning.'</p>'
-       .'<form method="post" name="evaluation" action="/adm/evaluate">'
+       .'<h2>'.$title.'</h2>');
+
+    if ($warning) {
+        $r->print(
+            &Apache::loncommon::confirmwrapper(
+                &Apache::lonhtmlcommon::confirm_success(
+            $warning,1)));
+    }
+    $r->print(
+        '<form method="post" name="evaluation" action="/adm/evaluate">'
        .'<input type="hidden" name="submiteval" value="true" />'
        .'<input type="hidden" name="postdata" value="'.$showurl.'" />'
     );
     $r->print(
         &Apache::lonhtmlcommon::start_pick_box()
        .&Apache::lonhtmlcommon::row_headline()
-       .$lt{'pleaserank'}
+       .$lt{'pleaserank'}.'<br />'
+       .'<span class="LC_info">'.$lt{'required'}.'</span>'
        .&Apache::lonhtmlcommon::row_closure()
     );
 
     foreach my $key ('correct', 'helpful', 'depth', 'clear', 'technical') {
         $r->print(
-            &Apache::lonhtmlcommon::row_title($lt{$key})
+            &Apache::lonhtmlcommon::row_title(
+                '<span title="'.&mt('required').'">'.$lt{$key}
+               .' <span class="LC_info">*</span></span>')
            .'<select name="'.$key.'">'
            .$standardoptions
            .'</select>'




More information about the LON-CAPA-cvs mailing list