[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm

albertel lon-capa-cvs-allow@mail.lon-capa.org
Fri, 20 Jul 2007 23:16:20 -0000


albertel		Fri Jul 20 19:16:20 2007 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  - BUG#4152, log roles assigned to users nohist_userrole hash for dc's so they can find users the've assined roles to.
  
  
  
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.897 loncom/lonnet/perl/lonnet.pm:1.898
--- loncom/lonnet/perl/lonnet.pm:1.897	Thu Jul 19 19:02:37 2007
+++ loncom/lonnet/perl/lonnet.pm	Fri Jul 20 19:16:19 2007
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.897 2007/07/19 23:02:37 albertel Exp $
+# $Id: lonnet.pm,v 1.898 2007/07/20 23:16:19 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -2113,6 +2113,14 @@
          {$trole.':'.$username.':'.$domain.':'.$runame.':'.$rudom.':'.$rsec}
                     =$tend.':'.$tstart;
     }
+    if (($env{'request.role'} =~ /dc\./) &&
+	(($trole=~/^au/) || ($trole=~/^in/) ||
+	 ($trole=~/^cc/) || ($trole=~/^ep/) ||
+	 ($trole=~/^cr/) || ($trole=~/^ta/))) {
+       $userrolehash
+         {$trole.':'.$username.':'.$domain.':'.$env{'user.name'}.':'.$env{'user.domain'}.':'}
+                    =$tend.':'.$tstart;
+    }
     if (($trole=~/^dc/) || ($trole=~/^ad/) ||
         ($trole=~/^li/) || ($trole=~/^li/) ||
         ($trole=~/^au/) || ($trole=~/^dg/) ||
@@ -2122,6 +2130,7 @@
          {$trole.':'.$username.':'.$domain.':'.$runame.':'.$rudom.':'.$rsec}
                     = $tend.':'.$tstart;
     }
+    &flushcourselogs();
 }
 
 sub get_course_adv_roles {