version 1.122, 2005/10/11 22:05:20
|
version 1.123, 2005/10/17 18:20:59
|
Line 2189 selection. Defaults to false.
|
Line 2189 selection. Defaults to false.
|
If true, only active students and course personnel will be |
If true, only active students and course personnel will be |
shown. Defaults to false. |
shown. Defaults to false. |
|
|
|
=item * B<emptyallowed>: |
|
|
|
If true, the selection of no users is allowed. Defaults to false. |
|
|
=back |
=back |
|
|
=cut |
=cut |
Line 2224 sub start_student {
|
Line 2228 sub start_student {
|
if (defined($token->[2]{'nextstate'})) { |
if (defined($token->[2]{'nextstate'})) { |
$paramHash->{NEXTSTATE} = $token->[2]{'nextstate'}; |
$paramHash->{NEXTSTATE} = $token->[2]{'nextstate'}; |
} |
} |
|
$paramHash->{'emptyallowed'} = $token->[2]{'emptyallowed'}; |
|
|
} |
} |
|
|
Line 2485 sub postprocess {
|
Line 2490 sub postprocess {
|
my $self = shift; |
my $self = shift; |
|
|
my $result = $env{'form.' . $self->{'variable'} . '.forminput'}; |
my $result = $env{'form.' . $self->{'variable'} . '.forminput'}; |
if (!$result) { |
if (!$result && !$self->{'emptyallowed'}) { |
$self->{ERROR_MSG} = |
if ($self->{'coursepersonnel'}) { |
&mt('You must choose at least one student to continue.'); |
$self->{ERROR_MSG} = |
|
&mt('You must choose at least one user to continue.'); |
|
} else { |
|
$self->{ERROR_MSG} = |
|
&mt('You must choose at least one student to continue.'); |
|
} |
return 0; |
return 0; |
} |
} |
|
|