]> git.mjollnir.org Git - moodle.git/commitdiff
For very large classes don't even try to show all the participants
authormoodler <moodler>
Tue, 12 Nov 2002 03:02:51 +0000 (03:02 +0000)
committermoodler <moodler>
Tue, 12 Nov 2002 03:02:51 +0000 (03:02 +0000)
user/index.php
user/lib.php

index c2126892ed4f8181d8981a844e5480eefec68270..8f6b1131e1266037f8a78e507efcf2efe3eaf1f8 100644 (file)
@@ -68,6 +68,9 @@
             foreach ($students as $student) {
                 print_user($student, $course, $string);
             }
+        } else if ($numstudents > $USER_HUGE_CLASS) {
+            print_heading(get_string("toomanytoshow"));
+
         } else {  // Print one big table with abbreviated info
             $columns = array("name", "city", "country", "lastaccess");
 
index b867fc9429e2854d67eab87ca4bd24596977676e..f8e027904750c26cbd2c36976c53a17c1bcc1378 100644 (file)
@@ -2,6 +2,7 @@
 
 $USER_SMALL_CLASS = 20;   // Below this is considered small
 $USER_LARGE_CLASS = 200;  // Above this is considered large
+$USER_HUGE_CLASS  = 500;  // Above this is considered too many to display
 
 /// FUNCTIONS ///////////////////////////////////////////////////////////