--- loncom/interface/coursecatalog.pm 2013/11/20 18:40:09 1.75 +++ loncom/interface/coursecatalog.pm 2013/12/24 19:15:10 1.76 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Handler for displaying the course catalog interface # -# $Id: coursecatalog.pm,v 1.75 2013/11/20 18:40:09 raeburn Exp $ +# $Id: coursecatalog.pm,v 1.76 2013/12/24 19:15:10 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -951,19 +951,20 @@ sub construct_data_table { $output .= ''.&mt('Self-enroll (if permitted)').''; &Apache::loncommon::end_data_table_header_row(); my (%numbers,%creditsum); - my ($showcredits,$defofficial,$defunofficial); + my ($showcredits,$defofficial,$defunofficial,$deftextbook); my %domdefaults = &Apache::lonnet::get_domain_defaults($domain); unless ($env{'form.currcat_0'} eq 'communities::0') { - if ($domdefaults{'officialcredits'} || $domdefaults{'unofficialcredits'}) { + if ($domdefaults{'officialcredits'} || $domdefaults{'unofficialcredits'} || $domdefaults{'textbookcredits'}) { $showcredits = 1; $defofficial = $domdefaults{'officialcredits'}; - $defunofficial = $domdefaults{'unofficialcredits'}; + $defunofficial = $domdefaults{'unofficialcredits'}; + $deftextbook = $domdefaults{'textbookcredits'}; } } my %courseinfo = &build_courseinfo_hash($courses,$knownuser,$domain,$details, $usersections,\@fields,\%fieldtitles, $wasactiveon,\%numbers,\%creditsum, - $showcredits,$defofficial,$defunofficial); + $showcredits,$defofficial,$defunofficial,$deftextbook); my %Sortby; foreach my $course (sort(keys(%{$courses}))) { if ($env{'form.sortby'} eq 'code') {