mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-19799 Upgraded calls to choose_from_menu_nested
This commit is contained in:
parent
0b280bbaa0
commit
641454c6b2
@ -2348,13 +2348,17 @@ function add_indented_names($categories, $nochildrenof = -1) {
|
||||
* @param integer $selected optionally, the id of a category to be selected by default in the dropdown.
|
||||
*/
|
||||
function question_category_select_menu($contexts, $top = false, $currentcat = 0, $selected = "", $nochildrenof = -1) {
|
||||
global $OUTPUT;
|
||||
$categoriesarray = question_category_options($contexts, $top, $currentcat, false, $nochildrenof);
|
||||
if ($selected) {
|
||||
$nothing = '';
|
||||
} else {
|
||||
$nothing = 'choose';
|
||||
$nothing = 'choosedots';
|
||||
}
|
||||
choose_from_menu_nested($categoriesarray, 'category', $selected, $nothing);
|
||||
$select = moodle_select::make($categoriesarray, 'category', $selected);
|
||||
$select->nothingvalue = $nothing;
|
||||
$select->nested = true;
|
||||
echo $OUTPUT->select($select);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user