--- loncom/auth/lonroles.pm 2010/09/03 19:20:51 1.240.2.16 +++ loncom/auth/lonroles.pm 2010/10/06 18:46:53 1.240.2.18 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # User Roles Screen # -# $Id: lonroles.pm,v 1.240.2.16 2010/09/03 19:20:51 raeburn Exp $ +# $Id: lonroles.pm,v 1.240.2.18 2010/10/06 18:46:53 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -138,7 +138,6 @@ use Apache::lonannounce; use Apache::lonlocal; use Apache::lonpageflip(); use Apache::lonnavdisplay(); -use Apache::lonmainmenu(); use Apache::loncoursequeueadmin; use GDBM_File; use LONCAPA qw(:DEFAULT :match); @@ -593,10 +592,14 @@ ENDENTERKEY return OK if $r->header_only; my ($crumbtext,$pagetitle,$recent,$show_course); + $show_course=&Apache::loncommon::show_course(); my $noscript=''.&mt('Use of LON-CAPA requires Javascript to be enabled in your web browser.').'
'.&mt('As this is not the case, most functionality in the system will be unavailable.').'

'; if ($custommenu) { - my $start_page = &Apache::loncommon::start_page('Main Menu',undef, - {'bread_crumbs' => 1}); + my $brcrum = {'bread_crumbs' => 1}; + if ($env{'form.destinationurl'} eq '/adm/gci_info') { + undef($brcrum); + } + my $start_page = &Apache::loncommon::start_page('Main Menu',undef,$brcrum); $r->print(<<"ENDCUSTOM"); $start_page
@@ -608,16 +611,25 @@ ENDCUSTOM $crumbtext = 'User Roles'; $pagetitle = 'My Roles'; $recent = &mt('Recent Roles'); - $show_course=&Apache::loncommon::show_course(); + my $standby=&mt('Role selected. Please stand by.'); if ($show_course) { $crumbtext = 'Courses'; $pagetitle = 'My Courses'; $recent = &mt('Recent Courses'); + $standby = &mt('Course selected. Please stand by.'); } - my $brcrum =[{href=>"/adm/roles",text=>$crumbtext}]; + my $brcrum = [{ href => '/adm/roles', + text => $crumbtext,}, + ]; + my $args; + if (($env{'user.domain'} eq 'gcitest') && (!$numdc)) { + $args = {bread_crumbs => $brcrum, + bread_crumbs_nomenu => 1}; + } else { + $args = {bread_crumbs => $brcrum}; + } + my $start_page=&Apache::loncommon::start_page($pagetitle,undef,$args); my $swinfo=&Apache::lonmenu::rawconfig(); - my $start_page=&Apache::loncommon::start_page($pagetitle,undef,{bread_crumbs=>$brcrum}); - my $standby=&mt('Role selected. Please stand by.'); $standby=~s/\n/\\n/g; $r->print(< 0) { - $switcher = &Apache::lonmainmenu::gcitest_switcher('cc',%courses); + $switcher = &Apache::loncommon::gcitest_switcher('cc',%courses); my $current; if ($env{'request.course.id'}) { $current = 'cc./'.$env{'course.'.$env{'request.course.id'}.'.domain'}. '/'.$env{'course.'.$env{'request.course.id'}.'.num'}; } - my $switcher_js = &Apache::lonmainmenu::gcitest_switcher_js($current,$numcourses); + my $switcher_js = &Apache::loncommon::gcitest_switcher_js($current,$numcourses); $r->print(<<"ENDSCRIPT");