Skip to content

Commit

Permalink
MDL-26243 calendar: display correct number of repeated events
Browse files Browse the repository at this point in the history
  • Loading branch information
mackensen authored and stronk7 committed Mar 14, 2012
1 parent 5d332d4 commit 2199fb2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 5 additions & 3 deletions calendar/event_form.php
Expand Up @@ -133,14 +133,16 @@ function definition () {
$mform->setDefault('repeats', 1); $mform->setDefault('repeats', 1);
$mform->disabledIf('repeats','repeat','notchecked'); $mform->disabledIf('repeats','repeat','notchecked');


} else if ($repeatedevents > 0) { } else if ($repeatedevents) {


$mform->addElement('hidden', 'repeatid'); $mform->addElement('hidden', 'repeatid');
$mform->setType('repeatid', PARAM_INT); $mform->setType('repeatid', PARAM_INT);


$mform->addElement('header', 'repeatedevents', get_string('repeatedevents', 'calendar')); $mform->addElement('header', 'repeatedevents', get_string('repeatedevents', 'calendar'));
$mform->addElement('checkbox', 'repeateditall', null, get_string('repeateditall', 'calendar', $repeatedevents), 'repeat'); $mform->addElement('radio', 'repeateditall', null, get_string('repeateditall', 'calendar', $this->_customdata->event->eventrepeats), 1);
$mform->setDefault('repeateditall', 'checked'); $mform->addElement('radio', 'repeateditall', null, get_string('repeateditthis', 'calendar'), 0);

$mform->setDefault('repeateditall', 1);


} }


Expand Down
2 changes: 1 addition & 1 deletion lang/en/calendar.php
Expand Up @@ -114,7 +114,7 @@
$string['quickdownloadcalendar'] = 'Quick download / subscribe to calendar'; $string['quickdownloadcalendar'] = 'Quick download / subscribe to calendar';
$string['recentupcoming'] = 'Recent and next 60 days'; $string['recentupcoming'] = 'Recent and next 60 days';
$string['repeatedevents'] = 'Repeated events'; $string['repeatedevents'] = 'Repeated events';
$string['repeateditall'] = 'Apply changes to all {$a} events in this repeat series'; $string['repeateditall'] = 'Also apply changes to the other {$a} events in this repeat series';
$string['repeateditthis'] = 'Apply changes to this event only'; $string['repeateditthis'] = 'Apply changes to this event only';
$string['repeatevent'] = 'Repeat this event'; $string['repeatevent'] = 'Repeat this event';
$string['repeatnone'] = 'No repeats'; $string['repeatnone'] = 'No repeats';
Expand Down

0 comments on commit 2199fb2

Please sign in to comment.