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

raeburn raeburn at source.lon-capa.org
Thu Jan 4 07:07:54 EST 2018


raeburn		Thu Jan  4 12:07:54 2018 EDT

  Modified files:              
    /loncom/interface	lonnavmaps.pm 
  Log:
  - Bug 6754 LON-CAPA as LTI Consumer
    - Replace "Answer Displayed" on Course Contents screen if item is an
      External Tool set to gradable with "Grade received" or "Grade available"  
  
  
Index: loncom/interface/lonnavmaps.pm
diff -u loncom/interface/lonnavmaps.pm:1.538 loncom/interface/lonnavmaps.pm:1.539
--- loncom/interface/lonnavmaps.pm:1.538	Thu Dec 21 03:50:57 2017
+++ loncom/interface/lonnavmaps.pm	Thu Jan  4 12:07:53 2018
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Navigate Maps Handler
 #
-# $Id: lonnavmaps.pm,v 1.538 2017/12/21 03:50:57 raeburn Exp $
+# $Id: lonnavmaps.pm,v 1.539 2018/01/04 12:07:53 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -702,7 +702,17 @@
     }
     if (($status == $res->ANSWER_OPEN || $status == $res->PARTIALLY_CORRECT)
 	&& $res->handgrade($part) ne 'yes') {
-        return &Apache::lonhtmlcommon::direct_parm_link(&mt("Answer available"),$res->symb(),'answerdate,duedate',$part);
+        my $msg = &mt('Answer available');
+        my $parmlist = 'answerdate,duedate';
+        if (($res->is_tool) && ($res->is_gradable())) {
+            if (($status == $res->PARTIALLY_CORRECT) && ($res->parmval('retrypartial',$part))) {
+                $msg = &mt('Grade received');
+                $parmlist = 'retrypartial';
+            } else {
+                $msg = &mt('Grade available');
+            }
+        }
+        return &Apache::lonhtmlcommon::direct_parm_link($msg,$res->symb(),$parmlist,$part);
     }
     if ($status == $res->EXCUSED) {
         return &mt("Excused by instructor");




More information about the LON-CAPA-cvs mailing list