MDL-21201 Feedback: hide anonymous responses in recent activity reports
authorJulien Boulen <julien.boulen@uhb.fr>
Thu, 26 Feb 2015 15:16:28 +0000 (16:16 +0100)
committerJulien Boulen <julien.boulen@uhb.fr>
Fri, 20 Mar 2015 15:28:11 +0000 (16:28 +0100)
mod/feedback/lib.php

index 68ab379..589d3d8 100644 (file)
@@ -393,9 +393,12 @@ function feedback_get_recent_mod_activity(&$activities, &$index,
         $sql .= " JOIN {groups_members} gm ON  gm.userid=u.id ";
     }
 
-    $sql .= " WHERE fc.timemodified > ? AND fk.id = ? ";
+    $sql .= " WHERE fc.timemodified > ?
+                AND fk.id = ?
+                AND fc.anonymous_response = ?";
     $sqlargs[] = $timemodified;
     $sqlargs[] = $cm->instance;
+    $sqlargs[] = FEEDBACK_ANONYMOUS_NO;
 
     if ($userid) {
         $sql .= " AND u.id = ? ";