--- loncom/interface/portfolio.pm 2008/12/10 21:46:58 1.202 +++ loncom/interface/portfolio.pm 2009/01/03 19:28:53 1.205 @@ -1,7 +1,7 @@ # The LearningOnline Network # portfolio browser # -# $Id: portfolio.pm,v 1.202 2008/12/10 21:46:58 kaisler Exp $ +# $Id: portfolio.pm,v 1.205 2009/01/03 19:28:53 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -138,7 +138,7 @@ END .'
' .'
' .''.$lt{'createdir_label'}.'' - .''.$groupitem + .''.$groupitem .'' .'' .'' @@ -694,7 +694,7 @@ sub rename { } else { &open_form($r,$url); $r->print('

'.&mt('Rename [_1] to [_2]?', &display_file() - , '').'

'); + , '').'

'); &close_form($r,$url); } } @@ -2245,26 +2245,30 @@ sub handler { &Apache::loncommon::content_type($r,'text/html'); $r->send_http_header; # Give the LON-CAPA page header - my @brcrum = [{href=>"/adm/portfolio",text=>"Portfolio Manager"}]; + my $brcrum = [{href=>"/adm/portfolio",text=>"Portfolio Manager"}]; + if ($env{"form.mode"} eq 'selectfile'){ $r->print(&Apache::loncommon::start_page($title,undef, {'only_body' => 1})); } elsif ($env{'form.action'} eq 'rolepicker') { $r->print(&Apache::loncommon::start_page('New role-based condition',undef, {'no_nav_bar' => 1, })); + } elsif ($caller eq 'coursegrp_portfolio') { + $r->print(&Apache::loncommon::start_page($title)); } else { - $r->print(&Apache::loncommon::start_page($title,undef,{bread_crumbs => @brcrum})); + $r->print(&Apache::loncommon::start_page($title,undef, + {'bread_crumbs' => $brcrum})); + if (!&Apache::lonnet::usertools_access($uname,$udom,'portfolio')) { + $r->print('

'.&mt('No user portfolio available') .'

'. + &mt('This is a result of one of the following:').''); + $r->print(&Apache::loncommon::end_page()); + return OK; + } } $r->rflush(); - if (!&Apache::lonnet::usertools_access($uname,$udom,'portfolio')) { - $r->print('

'.&mt('No user portfolio available') .'

'. - &mt('This is a result of one of the following:').''); - $r->print(&Apache::loncommon::end_page()); - return OK; - } my ($blocked,$blocktext) = &Apache::loncommon::blocking_status('port',$uname,$udom); if ($blocked) {