version 1.92, 2005/01/10 12:15:23
|
version 1.93, 2005/01/16 08:20:38
|
Line 2124 sub start_student {
|
Line 2124 sub start_student {
|
$helper->declareVar($paramHash->{'variable'}); |
$helper->declareVar($paramHash->{'variable'}); |
$paramHash->{'multichoice'} = $token->[2]{'multichoice'}; |
$paramHash->{'multichoice'} = $token->[2]{'multichoice'}; |
$paramHash->{'coursepersonnel'} = $token->[2]{'coursepersonnel'}; |
$paramHash->{'coursepersonnel'} = $token->[2]{'coursepersonnel'}; |
$paramHash->{'sctiveonly'} = $token->[2]{'activeonly'}; |
$paramHash->{'activeonly'} = $token->[2]{'activeonly'}; |
if (defined($token->[2]{'nextstate'})) { |
if (defined($token->[2]{'nextstate'})) { |
$paramHash->{NEXTSTATE} = $token->[2]{'nextstate'}; |
$paramHash->{NEXTSTATE} = $token->[2]{'nextstate'}; |
} |
} |
Line 3022 will make a "Finish Helper" button that
|
Line 3022 will make a "Finish Helper" button that
|
which is useful for the Course Initialization helper so the users never see |
which is useful for the Course Initialization helper so the users never see |
the old values taking effect. |
the old values taking effect. |
|
|
|
If the parameter "restartCourse" is not true a 'Finish' Button will be |
|
presented that takes the user back to whatever was defined as <exitpage> |
|
|
=cut |
=cut |
|
|
no strict; |
no strict; |
Line 3119 sub render {
|
Line 3122 sub render {
|
$result .= '</ul>'; |
$result .= '</ul>'; |
} |
} |
|
|
|
my $actionURL = $self->{EXIT_PAGE}; |
|
my $targetURL = ''; |
|
my $finish=&mt('Finish'); |
if ($self->{'restartCourse'}) { |
if ($self->{'restartCourse'}) { |
my $targetURL = '/adm/menu'; |
my $actionURL = '/adm/roles'; |
|
$targetURL = '/adm/menu'; |
if ($ENV{'course.'.$ENV{'request.course.id'}.'.url'}=~/^uploaded/) { |
if ($ENV{'course.'.$ENV{'request.course.id'}.'.url'}=~/^uploaded/) { |
$targetURL = '/adm/coursedocs'; |
$targetURL = '/adm/coursedocs'; |
} else { |
} else { |
Line 3129 sub render {
|
Line 3136 sub render {
|
if ($ENV{'course.'.$ENV{'request.course.id'}.'.clonedfrom'}) { |
if ($ENV{'course.'.$ENV{'request.course.id'}.'.clonedfrom'}) { |
$targetURL = '/adm/parmset?overview=1'; |
$targetURL = '/adm/parmset?overview=1'; |
} |
} |
my $previous = HTML::Entities::encode(&mt("<- Previous"), '<>&"'); |
my $finish=&mt('Finish Course Initialization'); |
my $next = HTML::Entities::encode(&mt("Next ->"), '<>&"'); |
|
$result .= "<center>\n" . |
|
"<form action='/adm/roles' method='post' target='loncapaclient'>\n" . |
|
"<input type='button' onclick='history.go(-1)' value='$previous' />" . |
|
"<input type='hidden' name='orgurl' value='$targetURL' />" . |
|
"<input type='hidden' name='selectrole' value='1' />\n" . |
|
"<input type='hidden' name='" . $ENV{'request.role'} . |
|
"' value='1' />\n<input type='submit' value='" . |
|
&mt('Finish Course Initialization') . "' />\n" . |
|
"</form></center>"; |
|
} |
} |
|
my $previous = HTML::Entities::encode(&mt("<- Previous"), '<>&"'); |
|
my $next = HTML::Entities::encode(&mt("Next ->"), '<>&"'); |
|
$result .= "<center>\n" . |
|
"<form action='".$actionURL."' method='post' target='loncapaclient'>\n" . |
|
"<input type='button' onclick='history.go(-1)' value='$previous' />" . |
|
"<input type='hidden' name='orgurl' value='$targetURL' />" . |
|
"<input type='hidden' name='selectrole' value='1' />\n" . |
|
"<input type='hidden' name='" . $ENV{'request.role'} . |
|
"' value='1' />\n<input type='submit' value='" . $finish . "' />\n" . |
|
"</form></center>"; |
|
|
return $result; |
return $result; |
} |
} |
|
|
sub overrideForm { |
sub overrideForm { |
my $self = shift; |
return 1; |
return $self->{'restartCourse'}; |
|
} |
} |
|
|
1; |
1; |