[LON-CAPA-cvs] cvs: loncom(version_2_11_X) /interface courseprefs.pm

raeburn raeburn at source.lon-capa.org
Sun Nov 13 11:20:55 EST 2016


raeburn		Sun Nov 13 16:20:55 2016 EDT

  Modified files:              (Branch: version_2_11_X)
    /loncom/interface	courseprefs.pm 
  Log:
  - For 2.11
    - Backport 1.83
  
  
Index: loncom/interface/courseprefs.pm
diff -u loncom/interface/courseprefs.pm:1.49.2.21 loncom/interface/courseprefs.pm:1.49.2.22
--- loncom/interface/courseprefs.pm:1.49.2.21	Mon Oct 24 18:10:08 2016
+++ loncom/interface/courseprefs.pm	Sun Nov 13 16:20:54 2016
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Handler to set configuration settings for a course
 #
-# $Id: courseprefs.pm,v 1.49.2.21 2016/10/24 18:10:08 raeburn Exp $
+# $Id: courseprefs.pm,v 1.49.2.22 2016/11/13 16:20:54 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1973,7 +1973,10 @@
     unless ((ref($settings) eq 'HASH') && (ref($ordered) eq 'ARRAY') && (ref($itemtext) eq 'HASH')) {
         return;
     }
-    my ($cathash,$categoriesform,$autocoowner,$clonedefaults);
+    my ($cathash,$categoriesform,$autocoowner,$clonedefaults,$disabled);
+    if ($noedit) {
+        $disabled = ' disabled="disabled"';
+    }
     my %domconf = 
         &Apache::lonnet::get_dom('configuration',
                                  ['coursecategories','autoenroll','coursedefaults'],$cdom);
@@ -1982,7 +1985,7 @@
         if (ref($cathash) eq 'HASH') {
             $categoriesform = 
                 &Apache::loncommon::assign_categories_table($cathash,
-                                                $settings->{'categories'},$crstype)."\n";
+                                                $settings->{'categories'},$crstype,$disabled)."\n";
         }
     }
     if (ref($domconf{'autoenroll'}) eq 'HASH') {
@@ -2124,10 +2127,6 @@
     );
     my $datatable;
     my $count = 0;
-    my $disabled;
-    if ($noedit) {
-        $disabled = ' disabled="disabled"';
-    }
     foreach my $item (@{$ordered}) {
         my $colspan;
         if ($item eq 'hidefromcat') {




More information about the LON-CAPA-cvs mailing list