--- loncom/interface/lonhelper.pm 2005/04/11 18:13:39 1.102 +++ loncom/interface/lonhelper.pm 2005/07/12 06:52:48 1.110 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # .helper XML handler to implement the LON-CAPA helper # -# $Id: lonhelper.pm,v 1.102 2005/04/11 18:13:39 albertel Exp $ +# $Id: lonhelper.pm,v 1.110 2005/07/12 06:52:48 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -2594,14 +2594,16 @@ BUTTONS # If the subdirectory is in local CSTR space my $metadir; if ($subdir =~ m|/home/([^/]+)/public_html/(.*)|) { - my $user = $1; - my $domain = $Apache::lonnet::perlvar{'lonDefDomain'}; + my ($user,$domain)= + &Apache::loncacc::constructaccess($subdir, + $Apache::lonnet::perlvar{'lonDefDomain'}); $metadir='/res/'.$domain.'/'.$user.'/'.$2; @fileList = &Apache::lonnet::dirlist($subdir, $domain, $user, ''); } elsif ($subdir =~ m|^~([^/]+)/(.*)$|) { $subdir='/home/'.$1.'/public_html/'.$2; - my $user = $1; - my $domain = $Apache::lonnet::perlvar{'lonDefDomain'}; + my ($user,$domain)= + &Apache::loncacc::constructaccess($subdir, + $Apache::lonnet::perlvar{'lonDefDomain'}); $metadir='/res/'.$domain.'/'.$user.'/'.$2; @fileList = &Apache::lonnet::dirlist($subdir, $domain, $user, ''); } else { @@ -3183,7 +3185,7 @@ sub render { my $targetURL = ''; my $finish=&mt('Finish'); if ($self->{'restartCourse'}) { - my $actionURL = '/adm/roles'; + $actionURL = '/adm/roles'; $targetURL = '/adm/menu'; if ($env{'course.'.$env{'request.course.id'}.'.url'}=~/^uploaded/) { $targetURL = '/adm/coursedocs'; @@ -3268,6 +3270,11 @@ sub render { 'answer_date' => "0_answerdate", 'tries' => '0_maxtries', 'weight' => '0_weight' ); + my %realParmName = ('open_date' => "opendate", + 'due_date' => "duedate", + 'answer_date' => "answerdate", + 'tries' => 'maxtries', + 'weight' => 'weight' ); my $affectedResourceId = ""; my $parm_name = $parmTypeHash{$vars->{ACTION_TYPE}}; @@ -3279,7 +3286,13 @@ sub render { # Print the granularity, depending on the action if ($vars->{GRANULARITY} eq 'whole_course') { $resourceString .= '