shifted hidden elements from standard_coursemodule_elements() into standard_hidden_coursemodule_elements() so that they can be included in a form without the other visible standard elements.

This commit is contained in:
jamiesensei
2006-11-13 09:18:47 +00:00
parent cac9c967df
commit d982f87978
+5 -2
View File
@@ -336,12 +336,15 @@ class moodleform_mod extends moodleform {
function standard_coursemodule_elements(){
$mform=$this->_form;
$mform->addElement('header', '', get_string('modstandardels', 'form'));
$mform->addElement('modgroupmode', 'groupmode', get_string('groupmode'));
$mform->setType('groupmode', PARAM_INT);
$mform->addElement('modvisible', 'visible', get_string('visible'));
$mform->setType('visible', PARAM_INT);
$this->standard_hidden_coursemodule_elements();
}
function standard_hidden_coursemodule_elements(){
$mform=$this->_form;
$mform->addElement('hidden', 'course', 0);
$mform->setType('course', PARAM_INT);