[LON-CAPA-cvs] cvs: loncom(GCI_3) /interface courseclassifier.pm
raeburn
raeburn@source.lon-capa.org
Fri, 03 Dec 2010 04:57:35 -0000
raeburn Fri Dec 3 04:57:35 2010 EDT
Modified files: (Branch: GCI_3)
/loncom/interface courseclassifier.pm
Log:
- Customization for GCI_3.
- Backport 1.11.
Index: loncom/interface/courseclassifier.pm
diff -u loncom/interface/courseclassifier.pm:1.8 loncom/interface/courseclassifier.pm:1.8.8.1
--- loncom/interface/courseclassifier.pm:1.8 Wed Jul 29 22:32:44 2009
+++ loncom/interface/courseclassifier.pm Fri Dec 3 04:57:35 2010
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Utilities for classifying courses based on institutional code
#
-# $Id: courseclassifier.pm,v 1.8 2009/07/29 22:32:44 raeburn Exp $
+# $Id: courseclassifier.pm,v 1.8.8.1 2010/12/03 04:57:35 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -39,8 +39,10 @@
my %courses = &Apache::lonnet::courseiddump($codedom,'.',1,'.','.','.', undef,undef,'Course');
foreach my $course (keys(%courses)) {
if (ref($courses{$course}) eq 'HASH') {
- $$coursecodes{$course} = $courses{$course}{'inst_code'};
- $totcodes ++;
+ if ($courses{$course}{'inst_code'} ne '') {
+ $$coursecodes{$course} = $courses{$course}{'inst_code'};
+ $totcodes ++;
+ }
}
}
return $totcodes;