--- loncom/interface/lonindexer.pm 2004/01/02 21:00:56 1.85 +++ loncom/interface/lonindexer.pm 2004/01/05 15:02:43 1.86 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Directory Indexer # -# $Id: lonindexer.pm,v 1.85 2004/01/02 21:00:56 www Exp $ +# $Id: lonindexer.pm,v 1.86 2004/01/05 15:02:43 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -956,7 +956,49 @@ sub display_line { $r->print (''. "\n"); - $r->print ("$listname$tabtag\n"); + $r->print ("$listname\n"); +# Attributes + my $filelink = $startdir.$filecom[0].'/default'; + + if ($hash{'display_attrs_0'} == 1) { + my $title = &Apache::lonnet::gettitle($filelink,'title'); + $r->print(' '.($title eq '' ? ' ' : $title). + ' '."\n"); + } + $r->print(' ', + $filecom[8]," \n") + if $hash{'display_attrs_1'} == 1; + $r->print(' '. + (localtime($filecom[9]))." \n") + if $hash{'display_attrs_2'} == 1; + $r->print(' '. + (localtime($filecom[10]))." \n") + if $hash{'display_attrs_3'} == 1; + + if ($hash{'display_attrs_4'} == 1) { + my $author = &Apache::lonnet::metadata($filelink,'author'); + $r->print(' '.($author eq '' ? ' ' : $author). + " \n"); + } + if ($hash{'display_attrs_5'} == 1) { + my $keywords = &Apache::lonnet::metadata($filelink,'keywords'); + # $keywords = ' ' if (!$keywords); + $r->print(' '.($keywords eq '' ? ' ' : $keywords). + " \n"); + } + if ($hash{'display_attrs_6'} == 1) { + my $lang = &Apache::lonnet::metadata($filelink,'language'); + $lang = &Apache::loncommon::languagedescription($lang); + $r->print(' '.($lang eq '' ? ' ' : $lang). + " \n"); + } + if ($hash{'display_attrs_7'} == 1) { + $r->print(' '); + } + if ($hash{'display_attrs_8'} == 1) { + $r->print(' '); + } + $r->print(''); } }