mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 01:16:44 +02:00
MDL-36614 calendar: Add support for storing the submitted event type
This commit is contained in:
parent
7133a88d06
commit
35ad5fc6bb
2 changed files with 14 additions and 11 deletions
|
@ -74,11 +74,10 @@ class calendar_addsubscription_form extends moodleform {
|
|||
$mform->addHelpButton('pollinterval', 'pollinterval', 'calendar');
|
||||
$mform->setType('pollinterval', PARAM_INT);
|
||||
|
||||
// Eventtype: 0 = user, 1 = global, anything else = course ID.
|
||||
list($choices, $groups) = calendar_get_eventtype_choices($courseid);
|
||||
$mform->addElement('select', 'eventtype', get_string('eventkind', 'calendar'), $choices);
|
||||
$mform->addRule('eventtype', get_string('required'), 'required');
|
||||
$mform->setType('eventtype', PARAM_INT);
|
||||
$mform->setType('eventtype', PARAM_ALPHA);
|
||||
|
||||
if (!empty($groups) and is_array($groups)) {
|
||||
$groupoptions = array();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue