[LON-CAPA-cvs] cvs: modules /msu localenroll.pm

raeburn lon-capa-cvs@mail.lon-capa.org
Tue, 20 Apr 2004 19:19:09 -0000


raeburn		Tue Apr 20 15:19:09 2004 EDT

  Modified files:              
    /modules/msu	localenroll.pm 
  Log:
  Supervisors can now be made course owners, so auto-enrollment will succeed in cases where a LON-CAPA course is requested by a supervisor as well the previously suapported cases -- instructor or TA (Record_Type 1 and 2).
  
  
Index: modules/msu/localenroll.pm
diff -u modules/msu/localenroll.pm:1.6 modules/msu/localenroll.pm:1.7
--- modules/msu/localenroll.pm:1.6	Thu Mar 11 17:00:04 2004
+++ modules/msu/localenroll.pm	Tue Apr 20 15:19:09 2004
@@ -178,7 +178,7 @@
             my ($dbh,$dbflag) = &connect_DB($$configvars{'lonDaemons'},'RO');
             if ($dbflag) {
 # Check if instructor is in CLIFMS for this course
-                my $clifmscount = $dbh->selectrow_array("SELECT count(*) FROM RO_CLIFMS_VIEW WHERE Term_Code='$sem' AND Subj_Code='$subj' AND Crse_Code='$crse' AND Sctn_Code='$sec' AND MSUNetID='$owner' AND (Record_Type='1' OR Record_Type='2')");
+                my $clifmscount = $dbh->selectrow_array("SELECT count(*) FROM RO_CLIFMS_VIEW WHERE Term_Code='$sem' AND Subj_Code='$subj' AND Crse_Code='$crse' AND Sctn_Code='$sec' AND MSUNetID='$owner' AND (Record_Type='1' OR Record_Type='2' OR Record_Type ='3')");
                 if ($clifmscount > 0) {
 	       	    my $loncount = $dbh->selectrow_array("SELECT count(*) FROM LONCAPA WHERE Term_Code='$sem' AND Subj_Code='$subj' AND Crse_Code='$crse' AND Sctn_Code='$sec' AND MSUNetID='$owner'");
             	    if ($loncount == 0) {