[LON-CAPA-cvs] cvs: loncom /interface lonstatistics.pm /interface/statistics lonproblemstatistics.pm

matthew lon-capa-cvs@mail.lon-capa.org
Wed, 27 Aug 2003 21:33:33 -0000


matthew		Wed Aug 27 17:33:33 2003 EDT

  Modified files:              
    /loncom/interface	lonstatistics.pm 
    /loncom/interface/statistics	lonproblemstatistics.pm 
  Log:
  Moving &Gather_Student_data to lonstatistics as it will be needed by 
  lonclassifystudent.pm.
  
  
Index: loncom/interface/lonstatistics.pm
diff -u loncom/interface/lonstatistics.pm:1.78 loncom/interface/lonstatistics.pm:1.79
--- loncom/interface/lonstatistics.pm:1.78	Fri Jun 20 14:50:17 2003
+++ loncom/interface/lonstatistics.pm	Wed Aug 27 17:33:33 2003
@@ -1,6 +1,6 @@
 # The LearningOnline Network with CAPA
 #
-# $Id: lonstatistics.pm,v 1.78 2003/06/20 18:50:17 matthew Exp $
+# $Id: lonstatistics.pm,v 1.79 2003/08/27 21:33:33 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -795,6 +795,44 @@
     }
     $Str .= "</select>\n";
     return $Str;
+}
+
+###############################################
+###############################################
+
+=pod 
+
+=item &Gather_Student_Data()
+
+Ensures all student data is up to date.
+
+=cut
+
+###############################################
+###############################################
+sub Gather_Student_Data {
+    my ($r) = @_;
+    my $c = $r->connection();
+    #
+    my @Sequences = &Apache::lonstatistics::Sequences_with_Assess();
+    #
+    my @Students = @Apache::lonstatistics::Students;
+    #
+    # Open the progress window
+    my %prog_state=&Apache::lonhtmlcommon::Create_PrgWin
+        ($r,'Statistics Compilation Status',
+         'Statistics Compilation Progress', scalar(@Students));
+    #
+    while (my $student = shift @Students) {
+        return if ($c->aborted());
+        my ($status,undef) = &Apache::loncoursedata::ensure_current_data
+            ($student->{'username'},$student->{'domain'},
+             $ENV{'request.course.id'});
+        &Apache::lonhtmlcommon::Increment_PrgWin($r,\%prog_state,
+                                                 'last student');
+    }
+    &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state);
+    $r->rflush();
 }
 
 ##################################################
Index: loncom/interface/statistics/lonproblemstatistics.pm
diff -u loncom/interface/statistics/lonproblemstatistics.pm:1.55 loncom/interface/statistics/lonproblemstatistics.pm:1.56
--- loncom/interface/statistics/lonproblemstatistics.pm:1.55	Mon Jul 28 11:30:46 2003
+++ loncom/interface/statistics/lonproblemstatistics.pm	Wed Aug 27 17:33:33 2003
@@ -1,6 +1,6 @@
 # The LearningOnline Network with CAPA
 #
-# $Id: lonproblemstatistics.pm,v 1.55 2003/07/28 15:30:46 matthew Exp $
+# $Id: lonproblemstatistics.pm,v 1.56 2003/08/27 21:33:33 matthew Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -310,44 +310,6 @@
 
 =pod 
 
-=item &Gather_Student_Data()
-
-Ensures all student data is up to date.
-
-=cut
-
-###############################################
-###############################################
-sub Gather_Student_Data {
-    my ($r) = @_;
-    my $c = $r->connection();
-    #
-    my @Sequences = &Apache::lonstatistics::Sequences_with_Assess();
-    #
-    my @Students = @Apache::lonstatistics::Students;
-    #
-    # Open the progress window
-    my %prog_state=&Apache::lonhtmlcommon::Create_PrgWin
-        ($r,'Statistics Compilation Status',
-         'Statistics Compilation Progress', scalar(@Students));
-    #
-    while (my $student = shift @Students) {
-        return if ($c->aborted());
-        my ($status,undef) = &Apache::loncoursedata::ensure_current_data
-            ($student->{'username'},$student->{'domain'},
-             $ENV{'request.course.id'});
-        &Apache::lonhtmlcommon::Increment_PrgWin($r,\%prog_state,
-                                                 'last student');
-    }
-    &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state);
-    $r->rflush();
-}
-
-###############################################
-###############################################
-
-=pod 
-
 =item &BuildProblemStatisticsPage()
 
 Main interface to problem statistics.
@@ -371,7 +333,7 @@
         return;
     }
     #
-    &Gather_Student_Data($r);
+    &Apache::lonstatistics::Gather_Student_Data($r);
     #
     #
     if ($output_mode eq 'html') {