mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
MDL-78621 mod_choice: verify limited responses before showing "full".
This commit is contained in:
parent
591cdd8211
commit
7d3eff209c
1 changed files with 4 additions and 1 deletions
|
@ -186,7 +186,10 @@ class mod_choice_renderer extends plugin_renderer_base {
|
||||||
} else if ($optionid > 0) {
|
} else if ($optionid > 0) {
|
||||||
$headertitle = format_string($choices->options[$optionid]->text);
|
$headertitle = format_string($choices->options[$optionid]->text);
|
||||||
if (!empty($choices->options[$optionid]->user) && count($choices->options[$optionid]->user) > 0) {
|
if (!empty($choices->options[$optionid]->user) && count($choices->options[$optionid]->user) > 0) {
|
||||||
if ((count($choices->options[$optionid]->user)) == ($choices->options[$optionid]->maxanswer)) {
|
if (
|
||||||
|
$choices->limitanswers &&
|
||||||
|
(count($choices->options[$optionid]->user) == $choices->options[$optionid]->maxanswer)
|
||||||
|
) {
|
||||||
$headertitle .= ' ' . get_string('full', 'choice');
|
$headertitle .= ' ' . get_string('full', 'choice');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue