public function definition() { global $CFG, $USER, $OUTPUT, $COURSE; $strrequired = get_string('required'); $mform =& $this->_form; $bmh = new local_quedit_manager(); $cats = $bmh->get_question_categories(); $options = array(); foreach ($cats as $cat) { $options[$cat->id] = $cat->name; } $mform->addElement('select', 'catid', get_string('select_category', 'local_quedit'), $options); $mform->setType('catid', PARAM_INT); $options = array(); $options['videoproctormc'] = 'Video Proctor Multi-Choice'; $options['multichoice'] = 'Multi-Choice'; $mform->addElement('select', 'qtype', get_string('qtype', 'local_quedit'), $options); $mform->setType('groupid', PARAM_INT); $mform->addElement('advcheckbox', 'includechildren', get_string('includechildren', 'local_quedit'), '', null, array(0, 1)); $mform->setType('includechildren', PARAM_INT); $mform->addElement('hidden', 'action', 'dogetcategory'); $mform->setType('action', PARAM_TEXT); $mform->addElement('submit', 'submitbutton', get_string('docat_label', 'local_quedit')); }